Skip to main content

Challenge

Routing work to users

Scenario

The MyTown 311 application allows residents to submit service requests. Specific members of the city government perform assignments in the Service Request case type. The services coordinator has identified three assignments that must be routed during case processing: Schedule repair, Review repair, and Perform repair. The Schedule repair and Review repair assignments must be routed to the municipal services coordinator. The Perform repair assignment should be routed to the appropriate operator based on the department responsible for the reported issue.

The services coordinator provides the following table that lists the conditions that determine how to route the Perform repair assignment.

Route to Value Field Comparator Value
Operator parksmgr@mytown Assigned Department is equal to "Parks and Recreation"
Operator dpwmgr@mytown Assigned Department is equal to "Public Works"
Operator trafficmgr@mytown Assigned Department is equal to "Traffic Management"

The following table provides the credentials you need to complete the challenge.

Role User name Password
Application Developer author@mytown pega123!

Challenge Walkthrough

You must initiate your own Pega instance to complete this Challenge.

Initialization may take up to 5 minutes so please be patient.

Detailed Tasks

1 Route an assignment to a specific user

  1. In the App Studio navigation pane, click Case types > Service Request to display the case life cycle. 
  2. In the Service Request case life cycle, click the Schedule repair step to display the configuration pane on the right.
  3. On the General tab, from the Route to drop-down, select Specific user, and verify the drop-down-list that follows defaults to User name.
  4. In the field under User name, enter servicecoordinator@mytown to route the Schedule repair task to the specific user.
    Note: Pressing the Down arrow in this field reveals the list of users available to work in the application.
    Routing an assignment to a specific user
     
  5. Click the Review repair step to display the configuration pane on the right.
  6. On the General tab, verify the Route to field defaults to Specific user, and the following field defaults to User name.
  7. In the field under User name, enter servicecoordinator@mytown to route the Review repair task to the specific user.
    Routing an Approve/Reject step to a specific user

2 Create a text property and configure as a calculated field

  1. In the Service Request case type, click the Data model tab.
  2. Click Add field and verify the Type drop-down defaults to Text (single line) to create a new text property.
  3. In the Name field, enter Assigned Department.
  4. To the right, click the Gear icon to open the property configuration window.
  5. In the window, expand the Advanced section to display the advanced configuration options.
  6. In the Advanced section, select the This is a calculated field (read-only) check box to display a new Calculation field.
  7. In the Calculation field, enter .RequestType.Department to calculate the value of the Assigned department as the value of the .RequestType.Department field.
    Assigned Department calculated field
  8. Click OK to complete the property configuration. Assigned Department is displayed as a calculated, read-only text property.

3 Route the assignment using business logic

  1. Click the Workflow tab to return to the Service Request case life cycle.
  2. Click the Perform repair step to display the configuration pane on the right.
  3. On the General tab of the configuration pane, from the Route to drop-down, select Use business logic.
    Routing an assignment using business logic
  4. To the right of the Route to drop-down, click the Gear icon to display the Business logic configuration window.
  5. In the configuration window, to the right of the circled 1 icon, verify that the Route to drop-down is set to Operator.
    Operator is the default routing for business logic
    Note: The Route to drop-down defaults to Operator. For this exercise, verify the default persists for each condition.
  6. In the Value field, enter parksmgr@mytown as the operator.
  7. In the second row, from the Field drop-down, select Assigned Department and verify the Comparator drop-down to the right defaults to is equal to.
    Note: For this exercise, the business logic remains as the default is equal to condition.
  8. To the left of the Select values link, in the Value field, enter Parks and Recreation to set the value to compare in the condition. The first condition is now set to route to parksmgr@mytown when the condition is true.
    Note: You can include quotation marks when you enter the condition value; otherwise, the system adds quotation marks automatically. For example, if you enter Parks and Recreation, the system adds the quotation marks, as shown in the following image.
    Routing an assignment using business logic. This condition routes the assignment to the parks manager when the assigned department is Parks and Recreation
  9. Click Add Condition to set the conditions for the dpwmgr@mytown and trafficmgr@mytown operators.
  10. For each condition-operator pairing, repeat steps 5-8 to route the Perform repair assignment to the appropriate operator by using business logic.
    Route to Value Field Comparator Value
    Operator dpwmgr@mytown Assigned Department is equal to "Public Works"
    Operator trafficmgr@mytown Assigned Department is equal to "Traffic Management"
  11. Under Add condition, to the right of otherwise, verify the Route to drop-down is set to Operator.
  12. To the right of the Route to drop-down, in the Value field, enter servicecoordinator@mytown to set the operator for the otherwise condition.
  13. In the lower right of the Business logic window, click Submit to route work for the Perform repair step based on these conditions.
     

4 Confirm your work (section not graded)

Note: Run the case with every type of service request to verify that each assignment is routed correctly based on the configured conditions.
  1. In App Studio, in the Service Request case life cycle, click Save and run to run a new case.
  2. In the New: Service Request view, complete any required fields before advancing the case.
  3. In the Report problem view, from the Type drop-down, select Road debris.
    Select Road debris request type
  4. Click Continue to advance to the next view.
  5. In the Identify location view, in the Address field, enter the address of the issue location.
  6. In the Identify submitter view, click Continue to advance to the next view.
  7. In the Request update view, click Finish to advance to the next view.
  8. At the top, in the Service Request case navigation bar, click Actions > Schedule repair to display the Schedule repair view.
  9. To the right, under Open assignments, verify that the assignment is now routed to Municipal Services Coordinator.
    Schedule repair assignment routed to Municipal Services Coordinator
  10. In the Due date calendar control, enter tomorrow’s date and click Submit to advance to the next step.
  11. Click Actions > Perform repair to display the Perform repair view.
  12. To the right, under Open assignments, verify the assignment is now routed to DPW Manager.
    Perform repair step that is routed to DPW Manager
  13. Complete the required fields, and then click Submit to advance to the next view. 
  14. Click Actions > Approval to display the Approval view.
  15. To the right, under Open assignments, verify the assignment is now routed to Municipal Services Coordinator.
    Approval routed to Municipal Services Coordinator
  16. Click Approve to resolve the Service Request case.


Available in the following missions:

If you are having problems with your training, please review the Pega Academy Support FAQs.

Did you find this content helpful?

40% found this content useful

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Academy has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice