cancel
Showing results for 
Search instead for 
Did you mean: 

How to pospone a task

3on
Champ in-the-making
Champ in-the-making
Hi,

I'd like to design a subprocess for following real-world scenario:
1. As a user I claim a human task which includes calling the client.
2. Client asks to be called later, e.g. at 5 PM.
3. I postpone the task till 5 PM to call the client again and unclaim it.
4. I claim another task from the queue and complete it.
5. Later I have no more active tasks, so I want to see all postponed tasks with their follow-up dates and eventually complete some of them.
6. At 5 PM the postponed task from step 1-3 is on the top of my queue again (if not resolved yet) and I claim it.
7. I call the client and either resolve the task or postpone it again.

Is it possible to implement such scenario in Activiti BPMN and Java?
We're querying tasks using TaskService in Java and not using Activiti Explorer.

Thanks.
1 REPLY 1

frederikherema1
Star Contributor
Star Contributor
You can leverage the due-date of a task. This can be set declaratively in the BPMN but also updated from our API. When the user want's to postpone the task, the due date is altered.

In order to remove the task from the "task list", you can either unassign the task (and involve the original assignee in the task using your custom identity-link type "postponer". Another option is to have a special variable on the task, which indicates it's postponed or not. In you're  task-list API-call you do, you can include a taskVariableValueEquals(…) to only include non-postponed tasks, for example. You can also leverage the "dueBefore()" or "dueAfter()" on the TaskQuery to filter what tasks pop up in a user's inbox.