Flow form
|
Use the Decision task () to reference a map value rule, decision table rule, decision tree rule or a Boolean expression that when evaluated produces a value that is the basis of branching in the flow.
At runtime, the system evaluates the decision rule based on inputs from the flow and the work object, and chooses one of the outgoing connectors based on the result. No user interaction or input is required.
For example, a decision shape for a credit card processing application may select one of three paths A, B, or C in the flow based on two input values — a card type (Standard, Silver, or Gold) and an amount.
Adding a Decision task to the flow
1. Drag the decision shape () and drop it onto the flow.
2. When the Decision Properties panel appears, complete the Name field.
3. Choose a decision rule Type: Map
Value
, Decision Tree
, Decision
Table
or Boolean Expression
.
4. Complete the fields that appear for that type. Click Apply when done.
5. Connect at least one incoming connector to of the shape.
6. Connect two or more outgoing connectors from the shape.
If the decision table or decision tree you reference has no more than five possible results, the outgoing connectors appear automatically when you drop the shape. You can add to, delete, rearrange, and modify such automatic connectors as desired. If the decision rule has more than five possible results, five connectors appear automatically. Make sure each distinct decision outcome has an appropriate connector condition.
Completing Decision Properties for map value rules
You can reference a one- or two-dimensional map value rule.
Field |
Description |
Name |
Enter a text name for this shape. Choose a name meaningful to application users who see this on the work object history display, the breadcrumbs control (for entry points), and the Where-Am-I? diagram. The task name is only descriptive; it does not affect runtime execution of the flow. This name also appears inside the Decision shape on the Diagram tab. |
Type |
|
Rule |
Select a map value rule, identified by the second key part. |
Row Input |
Optional. Enter a literal text value or a property reference that becomes the input value for the row of the map value at runtime. When you leave this blank, the row property identified on the Inputs tab is used as the source of the value. |
Column Input |
Optional. If the map value rule selected has two dimensions, enter a literal value or a property reference that becomes the input value for the column of the map value at runtime. When you leave this blank, the column property identified on the Inputs tab is used as the source of the value. |
Result in |
Optional. Select a target property to contain the result of the chosen rule. |
Audit Note |
Optional. Select or enter the name of a Rule-Message rule to control the text of an instances added to the work object history (the "audit trail") when a flow execution completes this shape. Process Commander includes a few dozen standard messages in the Work- class. (Through field value rules, the corresponding text on work object history displays can be localized. See About the Localization wizard.) Optionally, to reduce the volume of history detail instances, your application can prevent system-generated messages from being added to work object history. See Controlling the volume of generated work object history instances and the Pega Developer Network article PRKB-25196 How to control history instances written to the audit trail. |
Entry Point? |
Select to indicate that this decision task is an entry point, which a user can return to using the breadcrumbs control or the standard flow action Work-.Previous. The default is cleared. This check box works with Perform harness rules that include a breadcrumbs display and with assignments that offer the Work-.Previous flow action. In other cases, the check box has no effect. |
Only going back? |
This check box appears only when you select the Entry Point? check box. Select to restrict users at runtime who are at this entry point to choose only those entry points (on the breadcrumbs display) that identify earlier steps in the flow. Leave unselected to allow users to select any entry point of the flow when at this entry point. They can click the breadcrumbs control or tab to complete or visit an earlier or later step. For maximum user flexibility, leave this check box unselected if your flow accepts inputs in any order. However, this approach is typically not workable for flows that contain fork and decision shapes, or that have intermediate tasks that are not entry points. |
Click Apply . (To edit these shape properties after you save the Flow form, open the Diagram tab, right-click the shape, and select the Edit tab on the pop-up window.)
At runtime, the system evaluates the map value rule using
one or two values supplied by this settings dialog box, and
compute a result value. The decision result (a text value) is
the basis of the decision, using outgoing connectors and the
Status
comparison.
For example, if the map value returns values
"Red", "Green", or "Yellow",
the flow can include four connectors flowing from the
Decision task shape, all corresponding to Status comparisons.
One connector compares the returned value to "Red",
one to "Green", one to "Yellow", and a
fourth can become the default (Else
)
connector.
Completing Decision Properties for decision tree rules
Field |
Description |
Name |
Enter a text name for this shape. Choose a name meaningful to application users who see this on the work object history display, the breadcrumbs control (for entry points), and the Where-Am-I? diagram. .. For example: CustomerLimitCheck. The task name is only descriptive; it does not affect runtime execution of the flow. This name also appears inside the Decision shape on the Diagram tab. |
Type |
|
Rule |
Select a decision tree rule, identified by the second key part. |
Input |
Optional. Enter a literal text value or a property reference that becomes the input value for the decision tree at runtime. If you leave this blank, the system uses the value of the property identified on the Input tab. |
Result in |
Optional. Select a target property to contain the result of the chosen rule. |
Audit Note |
Optional. Select or enter the name of a Rule-Message rule to control the text of an instances added to the work object history (the "audit trail") when a flow execution completes this shape. Process Commander includes a few dozen standard messages in the Work- class. (Through field value rules, the corresponding text on work object history displays can be localized. See About the Localization wizard.) Optionally, to reduce the volume of history detail instances, your application can prevent system-generated messages from being added to work object history. See Controlling the volume of generated work object history instances and the Pega Developer Network article PRKB-25196 How to control history instances written to the audit trail. |
Entry Point? |
Select to indicate that this decision task is an entry point, which a user can return to using the breadcrumbs control or the standard flow action Work-.Previous. The default is cleared. |
Only going back? |
This check box appears only when you select the Entry Point? check box. Select to allow users at runtime who are at this entry point to choose only those entry points (on the breadcrumbs display) that identify earlier steps in the flow, already completed. Leave unselected to allow users to visit or complete or revisit the entry points of the flow in any order. Regardless of which step is currently displayed, they can click the breadcrumbs control to complete or revisit any earlier, or later, steps. For maximum user flexibility, leave this check box unselected if your flow allows inputs to arrive in any order. However, this approach is typically not workable for flows that contain fork and decision shapes, or that have intermediate tasks that are not entry points. |
Click Apply . (To edit these shape properties after you save the Flow form, open the Diagram tab, right-click the shape, and select the Edit tab on the pop-up window.)
At runtime, the system evaluates the decision tree rule
based on the input value you supply and the value of any
other properties it references. Your connectors leading from
this decision shape can use the result (the output of the
decision tree) in Status
comparisons.
The system evaluates connectors in order of decreasing likelihood. Flow execution continues along the first connector that evaluates to true.
Completing Decision Properties for decision table rules
Field |
Description |
Name |
Enter a text name for this shape. Choose a name meaningful to application users who see this on the work object history display, the breadcrumbs control (for entry points), and the Where-Am-I? diagram. For example: Customer Limit Check. The task name is only descriptive; it does not affect runtime execution of the flow. This name also appears inside the Decision shape on the Diagram tab. |
Type |
|
Rule |
Select a decision table rule, identified by the second key part. |
Result in |
Optional. Select a target property to contain the result of the chosen rule. |
Audit note |
Optional. Select or enter the name of a Rule-Message rule to control the text of an instances added to the work object history (the "audit trail") when a flow execution completes this shape. Process Commander includes a few dozen standard messages in the Work- class. (Through field value rules, the corresponding text on work object history displays can be localized.) Optionally, to reduce the volume of history detail instances, your application can prevent system-generated messages from being added to work object history. See Controlling the volume of generated work object history instances and the Pega Developer Network article PRKB-25196 How to control history instances written to the audit trail. |
Entry Point? |
Select to indicate that this decision task is an entry point, which a user can return to using the breadcrumbs control or the standard flow action Work-.Previous. The default is cleared. Because a decision task presents no user form, if a user clicks a breadcrumbs control to return to this entry point, flow processing resumes and pauses at the next assignment or other task that requires user input. |
Only going back? |
This check box appears only when you select the Entry Point? check box. Select to allow users at runtime who are at this entry point to choose only those entry points (on the breadcrumbs display) that identify earlier steps in the flow, already completed. Leave unselected to allow users to visit or complete or revisit the entry points of the flow in any order. Regardless of which step is currently displayed, they can click the breadcrumbs control to complete or revisit any earlier, or later, steps. For maximum user flexibility, leave this check box unselected if your flow allows inputs to arrive in any order. However, this approach is typically not workable for flows that contain fork and decision shapes, or that have intermediate tasks that are not entry points. |
Click Apply . (To edit these shape properties after you save the Flow form, open the Diagram tab, right-click the shape, and select the Edit tab on the pop-up window.)
At runtime, the system evaluates the decision table rule based on the input value you supply and the value of any other properties it references. Two connectors (one for true and one for false) leading from this decision shape can use the result.
The system evaluates connectors in order of decreasing likelihood. Flow execution continues along the first connector that evaluates to true.
Completing Decision properties for Boolean expressions
Field |
Description |
Name |
Enter a text name for this shape . Choose a name meaningful to application users who see this on the work object history display, the breadcrumbs control (for entry points), and the Where-Am-I? diagram. For example: Customer Limit Check. The task name is only descriptive; it does not affect runtime execution of the flow. This name also appears inside the Decision shape on the Diagram tab. |
Type |
|
Expression |
Enter an expression that returns true or false, for example: .myProperty == "Yellow" See About expressions. |
Result in |
Optional. Select a target property to contain the result of the expression. |
Audit Note |
Optional. Select or enter the name of a Rule-Message rule to control the text of an instances added to the work object history (the "audit trail") when a flow execution completes this shape. Process Commander includes a few dozen standard messages in the Work- class. (Through field value rules, the corresponding text on work object history displays can be localized. See About the Localization wizard.) Optionally, to reduce the volume of history detail instances, your application can prevent system-generated messages from being added to work object history. See Controlling the volume of generated work object history instances and the Pega Developer Network article PRKB-25196 How to control history instances written to the audit trail. When you plan to localize the application using this rule, so the application can support users in various languages or locales, choose the text carefully and limit text length to 64 characters. A field value rule with this text as the final key part is needed for each locale. When practical, choose a caption already included in a language pack, to simplify later localization. |
Entry Point? |
Select to indicate that this decision task is an entry point, which a user can return to using the breadcrumbs control or the standard flow action Work-.Previous. The default is cleared. |
Only going back? |
This check box appears only when you select the Entry Point? check box. Select to allow users at runtime to choose only those entry points (on the breadcrumbs display) that identify earlier steps in the flow, already completed. Leave unselected to allow users to visit or complete or revisit the entry points of the flow in any order. Regardless of which step is currently displayed, they can click the breadcrumbs control to complete or revisit any earlier, or later, steps. For maximum user flexibility, leave this check box unselected if your flow allows inputs to arrive in any order. However, this approach is typically not workable for flows that contain fork and decision shapes, or that have intermediate tasks that are not entry points. |
Click Apply .
At runtime, the system evaluates this Boolean expression.
In the connectors leading from this decision shape, you can
use the result in Status
comparisons.
The system evaluates connectors in order of decreasing likelihood. Flow execution continues along the first connector that evaluates to true.