Delegation
The aim of delegations is to transfer approval tasks to another solver. We divide delegations into automatic and manual.
Automatic delegation
In automatic delegations, a rule is first created according to which tasks are automatically delegated. A typical example is the user's departure on holiday.
In this case, the user creates a delegation, where he selects the validity of the delegation and the delegate (the user to whom the tasks will be moved). From the moment the created delegation is valid, tasks will be delegated to the delegate.
Delegations on the user detail
A new delegation tab has been added to the user detail. Here the user can create a new delegation and above all he sees an overview of all his delegations and also the delegations that delegate to him.
List of delegated tasks
In the detail of the delegation it is possible to see all tasks that have been delegated within the given delegation. Ie. as a user you have an overview of how many tasks have been delegated and in what state they are now.
The state can take the following states:
- In progress - The task was delegated and isn't completed yet.
- Executed - The task was delegated and completed.
- Canceled - The task was delegated and canceled (workflow was deleted).
Delegation type
The type of delegation we chose when creating the rule determines which tasks will be delegated.
In the product are by default three delegation types:
- Default delegation for all tasks - It will be used for all tasks for which no other delegation is defined (with a more specific type).
- Tasks approving role assignments by a manager - This type is used exclusively for tasks that are created as part of a role assignment approval workflow (approve-role-by-manager). This type is unique due to the definition of the delegate not only by the user but also by his contract. Thanks to this, we are able to create delegations for each delegator's contract. This will ensure that the resulting delegate will be selected on the basis of the delegator's contract (where the applicant's contract will be subordinate to the delegator's contract).
- Manual task delegation - It is created automatically on using the delegate operation over the agenda of assigned tasks. This type cannot be selected manually by user.
The relation between a specific type of delegation and a workflow process is realized by modifying the definition of workflow, where it is possible to add code of the type of delegation, according to which we want the tasks of the process to be delegated. If the workflow process does not contain any delegation type or there is no delegation definition for it, then delegations are searched for the default delegation type (Default delegation for all tasks).
For example workflow process approve-role-by-manager contains this delegation type:
<dataObject id="delegationType" name="delegationType" itemSubjectRef="xsd:string"> <extensionElements> <activiti:value>approve-role-by-manager-delegation-type</activiti:value> </extensionElements> </dataObject>
Manual delegation
Manual delegation allows a user to reassign his tasks to someone else. Are available as a bulk operation on the agenda of assigned tasks.
Manual delegation can also be used in the administrator mode, where the user has the right to see all unresolved tasks, all users. In this mode, it must be clearly defined who is the delegator for the selected tasks. To do this, the administrator can use a filter, where he selects only one user whose tasks he wants to delegate. If this filter is used, the delegator will be pre-filled according to it after starting the bulk operation. The second option is to select the delegator manually.
Manual delegations use the standard delegation agenda. This means that if the bulk operation reassign a task, a delegation definition will be created corresponding to this reassing. This new definition will contain a delegator and a delegate, depending on the settings of the bulk operation. Next, a link will be created between the definition and the task being reassigned.
Within each task delegation, a notification is sent to the task delegate, which informs him of the new task.
This notification is sent to the topic: core:delegationInstanceCreatedToDelegate
.
Authorization policies
Default settings of permissions for delegations are defined in the role 'Delegation (delegationRole)'.