Dynamic Duration
As explained in the section above, Manual and User Tasks should always have a Duration specified.
Intermediate Timer Events require a Duration as well, to be able to wait for the configured time and then move on with the Process flow.
The Duration for Manual and User Tasks can be static, as explained before, but it can also be dynamic.
Intermediate Timer Events will always have a dynamic Duration configuration.
What is Dynamic Duration?
Dynamic Duration means that it can vary according to business conditions.
Dynamic Duration is set using an On Enter business rule of the selected shape.
The expression used can be set in minutes or with a defined date.
Examples:
-
Duration in minutes:
Me.Duration = x
(minutes) -
Duration with a calculated date:
Me.EstimatedSolutionDate = Date
Important Considerations:
- If a Manual or User Task has a dynamic Duration configured, the static duration will be ignored.
- The dynamic Duration will be the one taken into account for the Work Portal colors and the Analysis Reports.
DO NOT use the following sentences:
Me.Case.getWorkItem(taskName).Duration
Me.Case.getWorkItem(taskName).EstimatedSolutionDate
These will not work.
Refer to Set tasks and timers durations for an example of how to set dynamic Durations.