...
This process is useful for cases where the standard “Share” action that can be used to share objects with other users is not sufficient. This “Share” action does not only share objects with selected users, it also notifies them about the shared document and requires a confirmation for the process to be completed. The process can be also used as a template for further customization of sharing use cases, if they are to be used in projects.
Process start
To initiate this process, you must have Edit rights for the object type you want to share. Select the “Share” action, add the users or user groups you want to share this document with and write a comment:
Version 1 und 2 | Version 3 |
---|
To start the process, click OK. The custom sharing logic is contained within the BeforeStartEvent which gives the users or user groups specified Read rights for the shared document.
With version 3, the startform assures that the process can only be started of the given Object type is shareable. If not, the OK button is inactive and the error message at field Object type is shareable signals that condition.
Inbox
Each member of the group receives the task 'Confirm sharing' in his inbox.
...
Version 1
| Version 1 and 2
| Version 1,2 and 3
|
---|
The model looks like this:
Version 1 | Version 2 | Version 3 |
---|
Version 1: The process model consists of one parallel container with an activity notice. This activity notice has to be confirmed by the recipients you specify at the beginning of the process.
With version Version 2 the : The initiator gets a notice as well when each addressed person has confirmed their task. And a deadline of two days in the future is set for the sharing confirmation task.
Version 3: The startform usually prevents the start if the object type is not shareable. Otherwise the main acticity BeforeStartEvent script reacts on the condition and leads to a notification which the initiator gets into his inbox afterwards.
Main Activity Settings
This process is available for each user and process. Change the Initiators and the Main object type to restrict its behavior.
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
// set object title indirectly as process subject $.variable('objecttitle').value = $.file.get()[0].title; // Share the object with users as members the organisational unit set in usergroup // Take into account that this code will echange the current sharing values of the group set in the variable 'usergroup' object type. // Todo: add this value to existing ones var processFile = $.file.get(); // get all process file objects into the array processFile var dmsObject = processFile[0]; // take the first element var putBody = { objects : [], organizationobjectstype : 'id', organizationobjects : [] }; putBody.objects.push( { itemid : dmsObject.id, type: dmsObject.type } ); putBody.organizationobjects.push($.variable('usergroup').value); $.http.post(); $.http.path('/service/dms/batch/addtoadditionalvisibility'); $.http.body(putBody); $.http.execute(); // extension of version 3: process result if(!response.reason) { $.variable('canbeshared').value = true; } else { // this condition will only occure, if the startform did not prevent the start in case of no shareable object types $.variable('canbeshared').value = false; } $.done(); |
Sending Tasks to all Recipients
...