Routing a form within the process

Learn to route a form within the process

Last published at: May 7th, 2024

Let’s expand the process built by using some of the other form-related steps.  

Let’s use the form definition “TestFormFile,” which looks as follows:

 

Let’s use the process definition “TestFormFileDef,” which looks as follows:

 

Let’s make the process route the newly created form instance to a user for entering data into the form. Drag and drop a “routeForm” step to the designer and connect the step to the “instantiateForm” step. Now, the process should look as follows. The red alert sign indicates the step property configuration is incomplete. 

 

Click the routeForm step to configure the Settings tab. You must provide the step and task names and select the Form Definition from the drop-down list.  Provide the variable reference (that is defined) that holds the Form Instance ID, as shown below. 

 

Click the routeForm step to configure the Advanced tab. You must provide the task description and select the users to route the form to by clicking on the selection button. You may also route the form to a group of users. Select the task priority from the drop-down list. Define the task duration value in minutes, hours, or days. You can configure the task reminders and email notifications if you need to. The email notifications require the email subject, content, and recipients list (may include internal and external email addresses). 

 

Click on the selection button to select the users to route the form. A popup window is displayed for configuration. Type in the user name to search, and use the right arrow key to select and the left arrow key to unselect the user. Click on the Save button to confirm. 

 

Click the Save button to save the workflow configuration. A confirmation message will appear in the top right corner.   

 

Let’s re-execute the process instance created in the previous steps.  Navigate to the Run—Process Instances page and select the process instance from the list. Click the Execute—Selected button to restart the process instance's execution. 

 

The Execute Instance popup window is displayed for confirmation. Click the OK button to proceed. 

 

The selected process instance's status is reset to “NotStarted.” To execute the instance, click on the Execute—Run Engine menu option.  

 

Once the engine executes, the status of the process instance should change to “sleeping.” To view its execution, click on the View—Render menu option. 

 

Let’s render the instance to view its execution by clicking on the View—Render menu option. The process instance is rendered on the new page, as shown below. Use the Select Steps to Exclude drop-down list to summarize a vast instance execution path. 

 

As the rendered workflow shows, the route form step will create a task for the user. Let’s open the task list and complete the form within the task. Then, you have to navigate to the Engage—Tasks page, as shown below. Select the Instances search filter and select the process instance from the drop-down list. The incomplete task assigned to the user is shown below. You may also search for the task using the Search textbox.    

 

The rendered task with the form displays as follows:

 

You may provide the values for the form fields and click the Submit button to complete them. The form instance now stores the form field values in XML format, and the process instance completes them. Once the task is completed, the process instance should be “Completed.”

 

You may also route the form to a queue using the “routeFormToQueue” step.