Skip to main content

         This documentation site is for previous versions. Visit our new documentation site for current releases.      

This content has been archived and is no longer being updated.

Links may not function; however, this content may be relevant to outdated versions of the product.

How to use the Wait shape to create mid-process dependencies

Updated on October 7, 2014


Use a Wait shape in your Pega 7 process to keep assignments from advancing either:

  • For a specified period of time
  • Until one or more cases of another case type reach a specified work status

When an assignment reaches a Wait shape, they system automatically puts it in a dependency workbasket. When the system detects that the dependency requirements are met, it advances the case to the next action in the process.

Using a simple example, this article describes how you can employ a Wait shape in your application.


The Purchase application contains a Purchase Order case type that is comprised of three stages. In Stage 2: Vendor Addition, the operator adds the items and, for each item, specifies a vendor. If the vendor is new, the process creates a Vendor Maintenance case, indicated by the Create Vendors step shown here: 


For each Vendor Maintenance case, a manager will:

  • Review the case 
  • Accept or reject the case
  • Resolve each case


In the current configuration, a Purchase Order case enters the vendor information and immediately advances the case to Stage 3: Quote, whether the vendor is approved or not.


You have been asked to design the Vendor Addition stage so a purchase order does not advance to the Quote stage until all the Vendor Maintenance cases spun off by an order are resolved.


To meet the requirement:

  1. In the Purchase Order case type, add a Wait for Approvals step to the Vendor Addition stage.
  2. In the new step, create a process that contains a Wait shape.
  3. In the Vendor Maintenance case type, determine the work status a case must achieve before a Purchase Order case can advance to the Quote stage.
  4. In the Wait shape, configure its properties.
  5. Test your configuration by creating a Purchase Order case.

Step 1: Add a Wait for Approvals step

  1. Open the Purchase Order case type from the Cases Explorer. This displays the Stages & Processes tab on the Case Designer landing page.
  2. In the Vendor Addition stage, add a step beneath Create Vendors step. Type the name Wait for Approvals in the text field.
  3. Click to the right of name and select Configure step behaviors from the pop-up menu.
    This opens the Step Configuration dialog.
  4. In the dialog, select Multi Step Process in the Step Type field. Click OK to save your step configuration and close the dialog.

Step 2: Create a Wait shape in the Wait for Approvals step

  1. Click the area beneath the steps in the Vendor Addition stage to display the Configure process detail link. Click it to open the stage's process diagram in process outline view.
  2. In the diagram, select the Wait for Approvals flow shape in the outline tree to display the default shapes.
  3. Delete the Assignment shapes, right-click the canvas, and select Add > Advanced Shapes > Wait from the pop-up menu.
  4. Connect the Start and End shapes to the Wait shape. Click the default [Wait] label beneath the shape and change the name to Wait for Approvals.
  5. Click the Save button on the Case Designer header to save your configuration.

Step 3: Determine the dependency work status

  1. Select Vendor Maintenance in the Cases Explorer. On the Stages & Processes tab, click the Configure Process Details link beneath Stage 3: Closure.
    This displays the Close Vendor Maintenance process diagram.
  2. Double-click the End shape to display its properties. Note that the Work status value is Resolved-Completed.
  3. Click Cancel to exit the dialog and return to the Vendor Addition Process Overview diagram.

Step 4: Configure the Wait shape's properties

  1. Select the Wait shape to display its properties.
  2. Enter the following information in these fields:
    • Wait Type — Dependency. A purchase order assignment (in the dependent case) will wait in a workbasket until a specified case (s) (defined by the case type in the Case of type field) reaches a work status (defined in the To reach status field) before the system processes the waiting purchase order assignment.
    • Wait for All. A purchase order must wait for all of its sub-cases to reach the defined work status before it can continue processing.
    • Cases of typePco-FW-PuchaseFW-Work-VendorMaintenance. This is the Vendor Maintenance sub-case type. Purchase order cases depend upon these cases reaching a specific status (defined in the To reach status field) before purchase order.
    • To reach statusResolved-Completed. The work status a vendor maintenance case must achieve before a purchase order can advance. This is the value you previously noted in Step 3: Determine dependency work status.
    • Scope Current Case. Processing searches all cases within the current case type and all its descendants when trying to fulfill a dependency. In this example, the vendor maintenance cases are sub-cases of its parent purchase request case.

      The complete dialog looks like this:
  3. Click OK to save your edits and close the dialog.

Step 5: Test your configuration

  1. Create a purchase request case by selecting Purchase Request from the Create menu.
  2. Enter two new vendors when adding two items in the Add Line Items screen flow.
  3. Complete the assignment. The process creates two new vendor maintenance cases for the new purchase request, PR-34. The assignment for vendor maintenance case VM-39 appears. Note that the purchase request case has not advanced to an assignment in the Purchase Request Step 3: Quote stage.
  4. Click the Purchase Request (PR-34) link to display its review form. Note the two new vendor maintenance assignments.
  5. Click the VM-39 Maintain assignment link to open its work form. Continue the process until the case is resolved.
  6. Open the purchase request review form again. Note that the VM-39 assignment no longer appears.
  7. Open and resolve the VM-38 assignment. Open the PR-34 review form again. Now that both vendor maintenance assignments have been resolved, the purchase request case has advanced to the first assignment in the Quote stage.

Allow operators to override the dependency

You can configure the Wait shape so that operators who have access to the dependency workbasket can choose to override the dependency requirement and manually advance the waiting case.

Do the following:

  1. Open the Vendor Addition stage in process outline view.
  2. Select the Wait for Vendor Approval shape on the outline tree to display the shape's properties.
  3. Expand the Advanced section on the form and select the Permit End User to perform checkbox.
  4. Click Save on the Case Designer header.
  5. Create a purchase request case as described previously. Note that there is an assignment in the purchase request review form named Await Vendor approval (Vendor Addition) that is assigned to the [email protected] dependency workbasket (defined in the Assigned to Workbasket field on the Wait shape's properties dialog).
  6. When the operator selects the assignment, the form displays the following in the action area:
    When the operator clicks the Step waiting and continue process button, the purchase request case immediately advances to the first assignment in the Quote stage.


Pega Platform 7.1.1 - 7.4 Case Management Financial Services Healthcare and Life Sciences Insurance Communications and Media Government Healthcare and Life Sciences Consumer Services

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best. is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us