diff --git a/assets/zip/personnal-data-export-navigator/Export.html b/assets/zip/personnal-data-export-navigator/Export.html index e407a539..1be6d0a6 100644 --- a/assets/zip/personnal-data-export-navigator/Export.html +++ b/assets/zip/personnal-data-export-navigator/Export.html @@ -34,6 +34,7 @@
  • Responses to surveys
  • Conversations Messages (ALL)
  • Conversations
  • +
  • Groups
  • @@ -202,6 +203,30 @@ + +
    + +

    Your groups membership

    + + + + + + + + + + + + + + + + +
    #IconNameMembers countVisibilityRegistration levelPosts creation levelVirtual directoryMembershipFollowing
    + +
    + @@ -216,6 +241,7 @@ + \ No newline at end of file diff --git a/assets/zip/personnal-data-export-navigator/assets/css/main.css b/assets/zip/personnal-data-export-navigator/assets/css/main.css index f0643a4a..04bd4af1 100644 --- a/assets/zip/personnal-data-export-navigator/assets/css/main.css +++ b/assets/zip/personnal-data-export-navigator/assets/css/main.css @@ -31,6 +31,9 @@ h1 { margin-right: 5px; } +.group-logo { + width: 50px; +} /** diff --git a/assets/zip/personnal-data-export-navigator/assets/js/categories/groups.js b/assets/zip/personnal-data-export-navigator/assets/js/categories/groups.js new file mode 100644 index 00000000..b92556ca --- /dev/null +++ b/assets/zip/personnal-data-export-navigator/assets/js/categories/groups.js @@ -0,0 +1,49 @@ +/** + * Groups membership + * + * @author Pierre Hubert + */ + +/** + * Apply the list of groups + */ +function ApplyGroups() { + const target = byId("groups-list-table") + + data.groups.forEach(group => { + + let groupTR = createElem2({ + appendTo: target, + type: "tr" + }); + + const addCell = (content) => createElem2({ + appendTo: groupTR, + type: "td", + innerHTML: content, + }) + + addCell(group.id) + + let groupLogoCell = createElem2({ + appendTo: groupTR, + type: "td" + }); + + let groupLogo = createElem2({ + appendTo: groupLogoCell, + type: "img", + class: "group-logo", + src: getFilePathFromURL(group.icon_url) + }); + + addCell(group.name) + addCell(group.number_members) + addCell(group.visibility) + addCell(group.registration_level) + addCell(group.posts_level) + addCell(group.virtual_directory) + addCell(group.membership) + addCell(group.following ? "Yes" : "No") + }); +} \ No newline at end of file diff --git a/assets/zip/personnal-data-export-navigator/assets/js/main.js b/assets/zip/personnal-data-export-navigator/assets/js/main.js index 94c8cc77..7ea49f02 100644 --- a/assets/zip/personnal-data-export-navigator/assets/js/main.js +++ b/assets/zip/personnal-data-export-navigator/assets/js/main.js @@ -81,6 +81,7 @@ xhr.onload = function(){ ApplySurveyResponses(); ApplyAllConversationMessages(); ApplyConversations(); + ApplyGroups(); } xhr.send(null); \ No newline at end of file