Is it possible to reset a task deadline after a user accepts the task?

Is it possible to reset a task deadline after a user accepts the task?

For example: we would like to set the task deadline to the accepted date plus five days.

OriginalPostID-219694

OriginalPostID-219694

  Discussion posts and replies are publicly visible

  • 0
    Certified Senior Developer
    Task deadline triggers as soon as task is initialized and cannot be changed.
    I think you may have to create that logic in process.
  • Can a process be triggered when a user accepts a task?
  • 0
    Certified Senior Developer
    There is a work around.
    Information we know:
    Task has a deadline of 5 days, once the user accepts the task.
    tp!startTime on portal report is automatically updated when the user accepts the task.

    Solution:
    By using queryProcessAnalytics we can identify when was the task accepted by the user and can calculate the due date accordingly.
    Now, if you want to show the due date on the task, then it can be easily calculated. Once the user make any interaction on the UI / submits the task, we can capture that due date and all information in process variable to save in database.

    If you are showing the due date on the UI, You may need to consider what would you want your user to see when the user hasn't accepted the task.
  • 0
    Certified Senior Developer
    Hey Cheryl

    I may be wrong about the restting of the tp!startTime.
    If I am not wrong it used to reset when user used to accepts the task, but when I try that in 16.2, it does not.
  • @cherylr To the best of my knowledge, definitely there is a way to reset the Task Deadline and it can be done by making use of the smart service namely 'Set Task Deadline' in the 'Task Smart Services Plug-in' Shared Component present at http://bit.ly/28TJMpN.

    The only problem I can see here is, your interest lies in resetting a deadline when user accepts the task and this isn't possible afaik because there isn't a way currently to capture the events on the Task such as Reassign Task, Save Changes, Reject Task, Accept Task and so we can't associate any functionalities with them in a direct way. You need to plan for an alternate way in order to make this happen and here is one of the few ways:

    1. Build a Task Report which consists of Tasks and build the capability of Acceptance(An option to select one task and am Accept button/link and for acceptance, you can opt for the smart service by name 'Accept Task' ).
    2. Always make sure that a User accepts the Task from this Task Report itself. In order to make this happen, you may need to educate the User. As you are going to build a process anyhow that takes care of Acceptance of the chosen Task, you can also include the functionality of resetting the deadline next to acceptance of Task.

    An other way is to include this functionality in the User Input Task itself, and in order to make this happen, we should instruct the User to interact with a component on the form as and when he accepts the Task. This is because, building the functionality as desired by you definitely needs interaction with a SAIL component in order to trigger.

    It's not quite elegant and I wouldn't personally recommend implementing such workarounds. Nevertheless, there is a way to do it, provided if it is really a value addition to business.

    It would be really nice to have capability to capture the OOTB events associated with a Task. Please do let us know in case of any follow-up questions and we would be more than happy to answer.