Task Step

Use this step to configure and route the task to users.

Last published at: July 27th, 2024

Description:

This step routes a task to a selected number of users. 

 

Inputs

  • routeTo – Select users to route to 
  • routeToRoles – Select roles to route to 
  • taskDesc – Description of the task
  • taskBody – Body of the task/task description
  • routedItem – Item that is routed
  • showURL – URL to render within the task
  • emailAddressses- Email addresses to route the task to
  • priority – Priority of the task
  • daysToComplete - # of days, minutes, hours, and months to complete the task by
  • expiryType – Task expire type
  • includeWeekends – Include Weekends
  • useFullDuration - the task uses the full duration and continues
  • taskRoutingRules- Task routing rules types
  • taskReminder- Set task reminder to send reminder emails
  • waitForAll – Yes = all users must act on the task, No = requires only 1 user to act on the task
  • storeRouteToUsers – variable to store what users the task was routed to
  • sendEmailNotifications – Yes = email notification will be sent to each user for the task
  • fromEmail – From email address
  • emailSubject – Subject of the email message
  • emailBody – Body of the email message
  • emailFiles – Email file attachments 
  • sendExpireEmail - Send expired email notification
  • sendAckLink - Send acknowledgment link
  • approveButtonLabel--Label for approval button
  • rejectButtonLabel--Label for reject button
  • hideRejectButton--Hide reject button
  • userCanReAssign – Yes/No. Users can re-assign tasks to another active user during run time. 
  • commentRequired - User comments are required mandatory
 

 

Returns

  • completed – task was approved and completed
  • rejected – task was rejected
  • timeout - task timed out
 

 

Step Returns Collection

The following step properties contain return values when the task is completed or rejected (run time). 

  • stepReturn.routeTo – Includes the user's GUID reference 
  • stepReturn.completedByUsers – Includes the user's GUID reference
  • stepReturn.rejectedUserList - Includes the user's GUID reference
 

 

Usage:

 

 

Example:

Let’s build and execute the taskDef example.          

  • Create a new definition called “taskDef.
  • Select the definition and click the “design” button
  • Drag the above controls from the toolbox and connect as shown above
  • Click on the “task” step to configure its “Settings” properties, as shown in the graphic below. Provide a name to the step. Provide a task description. Note: The task step has 1 incoming and 0 outgoing connections, as per the legend. 

 

  • Click on the globe icon to globalize the task step using the following UI. Select the language from the dropdown list. Click on the “Translate” button to convert the description to the chosen language. Click on “Save” to confirm changes. 

 

  • Click on the “task” step to configure its “Advanced” properties, as shown in the below. Click on the button to select the users to route to. Next, click on the button to select the application role (users) to route to. Provide the task detail description. Provide information on items that are routed. Provide URL link to render (external links require internet access). Provide an external email address list (semi-colon separated). 

 

  • Continue configuring the “task” step's “Advanced” properties, as shown below. Select task priority from the list (low, medium, high, normal, urgent). Select the task expiration type (days, hours, months, minutes). Provide the task completion duration value. Select include weekends option as Yes, if desired.  

 

  • Select Yes for the task to wait for the full duration even after completion. 

 

  • Task locks - select task routing rules (default, task lock, most miniature # of tasks in total, most minor # of tasks in duration). “Default” means the task has no lock status during run time. “Task lock” means the task is locked by one of the users during runtime. A task is assigned to one of the users having the most miniature # of tasks by count during runtime. The task is assigned to one of the users having the most miniature # of tasks by time duration during run time. Configure task reminders. Configure if the task needs to wait till all users have responded (when routed to more than one user). Provide a variable or global reference to hold the routed users list on task completion. The variable may be created before or later when the process definition is saved. Select YES to send an email notification (the Status determines the notification duration - Status - Settings - Email - Notifications section). Select Yes if separate emails are to be sent to users (which include different task IDs in the URL). Provide the FROM email address (other than default). Provide the email subject text.  Click on the button to configure email attachments on the app server.   

 

  • Continue configuring the “task” step's “Advanced” properties, as shown below.  Click on the button to provide the email content (body). Click on the button to configure the email file attachments (from the app server path). Provide Email CC list (semi-colon separated). Select YES to send expired notifications (the notification duration is determined by the Status - Status - Settings - Email - Expired Task Notifications section). Select YES to email an acknowledgment link. Provide new text to change the Approve and Reject button labels (e.g., OK and Not OK). Select YES to hide the Reject button. Select YES to re-assign the task during run time. Select YES for mandatory task comments.    

 

  • Search for users (by first 3 chars) and select from the list on the left pane using the arrow buttons. The task can be assigned to more than one user. 

 

  • The Task can also be assigned to a user GUID (provided we know the value beforehand). Configure and provide the variable containing the reference to the user's GUID. The username selection should be empty as the function is mutually exclusive, as shown in the image below. 

 

  • The Task can also be assigned to users grouped by application role. Use the arrow buttons to select from the list on the left pane.

 

  • Click on Task Reminder to set task reminder intervals. Enable "Send Email Notification" to ON. Task reminders configured with a positive value are calculated from the task created date. Task reminders configured with a negative value are calculated by reducing that duration from the task due date. The task reminder message body supports line breaks.

 

  • Task reminders configured with a negative value are calculated by reducing that duration from the task due date. 

 

  • Use Variable(s) references for more meaningful reminder messages, as shown below.

 

  • Use Variable(s) references for more meaningful reminder messages, as shown below.

 

  • Click on the Email body and use the existing template (you can edit the existing template as well) as the email body or create a custom template as the email body.

 

  • Click on Replace Link(s) or Variable(s) or Global(s) and select any reference to add a more meaningful email message. 

 

  • Save the process definition, create a process instance, and execute. The Task step should route tasks to users.
  • Navigate to the Engage - Tasks page to view the Tasks routed to the resource. 
  • NOTE: When routing a Task/Form to the queue, the system recomputes the task expiration date when it is assigned to a user from the queue.
  • The “Logging” setting configuration is necessary for documentation and also measures the workflow progress and the percent complete. This is achieved by configuring the step state and percent fields individually, as shown in the images below. Configure the “Logging” using the following properties. The "Send Test Mail" feature is provided to send a test email with the contents configured in the email body to the current (logged-in) user. 

 

Learn how to use Replace Links in the task email body