Tutorial: Defining Subtask-Driven Actions

This example describes how to add a Subtask transition that posts an item from one application to another. After you add the Subtask transition, you can define actions that transition principal tasks based on the subtask's values in a Binary/Trinary or Single Selection field used to determine subtask status. For example, in a Human Resources (HR) workflow that requires an Information Technology (IT) department to purchase a computer for a new employee, you can create a Subtask transition that submits a task into the IT workflow for the purchase. After IT closes its task in its workflow, the task in the HR workflow is automatically closed.

Prerequisites:

The following must be set up before you perform this procedure:
  • Two applications, named New Hires and IT Tickets
  • One application workflow for each application, named New Hires and Asset Management, respectively.
  • Binary/Trinary field named Subtask Status in the IT Tickets table, with In Progress and Completed values.
  • In the New Hires workflow:
    • Waiting for IT "active" state
    • Send to IT "subtask" transition that leads from the New state to the Waiting for IT state.
    • Closed "completed" state
    • Resolved by IT "regular" transition that leads from the Waiting for IT state to the Closed state.
  • In the Asset Management workflow:
    • In Progress "active" state
    • Assign "regular" transition that leads from the New state to the In Progress state
    • Closed "completed" state
    • Close "regular" transition that leads from the In Progress state to the Closed "completed" state
Note: A process app that defines subtask-driven actions requires at least two applications. The applications can be in the same process app, or can be in another process app, if the current process app contains references to them. See About References for more information.

To set up a subtask-driven action:

  1. Configure the Send to IT transition in the New Hires workflow.
    1. On the Options tab of the transition Property Editor, select the Quick Transition check box.
    2. On the Post Options tab of the transition Property Editor:
      • In the Post Application list, select IT Tickets.
      • In the Post Table list, select IT Tickets.
      • In the Use submit transition list, select Asset Management : Submit.
      • For When finished, show, select New Item.
      • In the Item Link Type list, select 2-Way, no triggers.
  2. Set the subtask status in the Asset Management workflow.
    1. Select the Completed state. This is the state to which the subtasks are transitioned.
    2. On the General tab of the state Property Editor, in the Subtask list, select Subtask Status.
    3. Select the Close transition.
    4. On the Field Overrides tab of the transition Property Editor, select the Subtask Status field, select the Override field properties check box, select Set to Default, and then select Completed in the Default Value list.
    5. Still on the Field Overrides tab, make sure that there are no required fields for this transition, or set default values for fields that require values.
  3. Create an action in the New Hires workflow that will transition principal items, based on the value of the Subtask Status field.
    1. Select the Waiting for IT state. This is the state in which principal items remain while they wait for subtasks to complete.
    2. On the Actions tab of the state Property Editor, click New.
    3. In the Action Wizard that opens, select Transition, and then click Next.
    4. Select This item, and then click Next.
    5. Select Subtask's Status.
    6. Select all are, select Completed, and then click Next.
    7. Select the New Hires:Resolved by IT (Waiting for IT->Close) transition, and then click Finish.
    8. Click the Resolved by IT transition.
    9. On the Field Overrides tab of the transition Property Editor, make sure there are no restrictions, such as Item Type restrictions, on the transition.
  4. Test the process app.
    1. In the SBM User Workspace, submit an issue into the New Hires project.
    2. Click the Send to IT transition button.
    3. Submit an issue into the IT Tickets project from the window that opens.
    4. Click the Assign transition button.
    5. Click the Close transition button. The IT Tickets subtask item is in the Closed state.
    6. Click the principal item in the Subtasks or Attachments section. The New Hires principal item opens, and is in the Closed state.
    Note: In the SBM User Workspace, users are presented with a list of projects into which they have privileges to submit items. If only one project is valid for submission, the submit form opens for that project. If multiple projects are valid for submission, you can specify a single project by selecting a value in the Use submit transition field in the transition Property Editor. For more information, see Post Options Tab of the Transition Property Editor. In addition, in SBM Application Administrator, administrators can configure transitions in projects to select a specific project into which all items are submitted.

Related Topics

Using the Action Wizard

Using Actions