AnsweredAssumed Answered

Task DueDate / Period

Question asked by skay on Nov 4, 2014
Latest reply on Sep 23, 2016 by debajyoti.deb
Hello,

My need has been partially resolved into

http://forums.activiti.org/content/time-duration-support-user-task-due-date

Though I'm puzzled.
Would the current implementation / the resolveDueDate 'roll' after the DateTime.now()?

UserTaskActivityBehavior

if(taskDefinition.getDueDateExpression() != null) {

} else if (dueDate instanceof String) {
          BusinessCalendar businessCalendar = Context
            .getProcessEngineConfiguration()
            .getBusinessCalendarManager()
            .getBusinessCalendar(DueDateBusinessCalendar.NAME);
          task.setDueDate(businessCalendar.resolveDuedate((String) dueDate));
        }


DueDateBusinessCalendar

  public Date resolveDuedate(String duedate) {
    try {
       
       // check if due period was specified
       if(duedate.startsWith("P")){
          return DateTime.now().plus(Period.parse(duedate)).toDate();
       }

Shoud that mean that due date will alway been pushed away in the future of the amount of specified period each time the humanTassk is claimed/trigged ??

Outcomes