We came across a situation where we had to merge the groups into one so as to provide collaborative place to look for same domain. As a solution to this problem, we designed an app which will merge the groups with the data and members into the target group; app named 'Merge Groups'.
There is a thread which requires similar solution; Is it possible to merge two exisitng groups into one?.
1) Migrating memberships from multiple groups to one.
As the member from the to be merged group should be a member in merged group so as to get the updates.
2) Associate selected stream(s) of user with the new group.
To get the updates.
3) Migrating content from multiple groups to one.
How the app works?
The scope of this app is restricted to groups and it will appear under action tab.
The app shall be opened into the group which should be target group in which user wants to merge the other groups.
Steps followed to perform the operation:
1.Click on Merge Groups from group's action section, it will open an app in popup as below
2.Select the source groups from the place picker that will be invoked once you click on 'Select Source Group(s)'.
User can select upto 10 groups to be merged into one.
3. Select the stream(s) which you want members to associate with the new group.
In our app Email Watches is the custom stream which is used for getting email notifications for activities.
You will find some more examples of custom streams here : Examples of Custom Streams
4. Submit the merge request.
Once process is submitted user gets notification about report of the process.
Whenever the process is done, the user is sent all report in email. (which might take some time depending on number of members and data to move)
Once user click on 'Submit request' we do request to node server to process the request:
In app.xml we have added a jive connects api setting to call the service in above file.
as you could see; we have used custom service named mergeService as a middleware for request and response to the app.
code snippet from server side:
Only superAdmins and groupAdmins will have access to this app.
We have added logger to log all the operations which includes: operation done, operation name, operation status.
As part of the merge operation, All the source groups will get deleted and the target group will have all the content type enabled.
Please find the code under : ThoughtWorksInc/merge-groups · GitHub; licensed under AGPL.
For getting started with Jive node sdk: Getting Started with the Jive Node SDK