Skip to main content
Mitratech Success Center

Condition Builder

Conditions are true or false statements that are evaluated in order to determine an appropriate response. Process Director includes a Condition Builder that enables you to create conditions to test nearly any value you desire.

You will see the Condition Builder in many different places, such as when to make a form field enabled or hidden, or what value to return from a Business Rule. Adding a condition to a specific option makes it easy to set a value or perform an action based on your preference.

Adding a Condition

When the Condition Builder has been invoked, you may add a condition by selecting the button “Add Condition”.

image

Once you click the Add Condition button, the first conditions row will appear, and the first control in the row (we refer to this as the “left hand side” of the condition) is a Picker control that will display the text, “Form Field” in most contexts. You will use this picker control to set the variable that you will evaluate for the condition. The middle control is a selector that enables you to pick the method for comparing the system variable to a desired value. We refer to this as the operator. Finally, there is, for most variable types, a third field, which is the desired value to which you wish to compare the system variable. We refer to this as the Right hand side" of the condition.

Not all system variables will have a desired, or right hand side value. For instance, boolean variables only return true or false. As such, they are not compared to a desired value, merely evaluated to determine if they are true or false.

image

System Variable

Click the Picker Control’s Build button to reveal the Choose System Variable dialog box. This dialog box contains all of the system variables that are available for evaluation.

image

All of the system variables are organized in a dropdown menu that divides the system variables into a number of categories, as shown above. Use the dropdown menu to select the appropriate system variable. Once you have selected the system variable, click the OK button to close the dialog box and set the system variable in the condition row. For this example, we will use a notional Form Field named "Text1".

Operator

Once the variable have been selected, you must choose an operator for the variable, i.e., the method we will use to compare the variable to the desired value. A number of operators are available, and the type of available operators will depend on the type of system variable you select. A boolean system variable, for instance, will only allow you to select whether the variable is true or false, while a text variable will provide a much wider array of choices.

image

In general, the following operators are available:

= (Equals) - This operator requires that the system variable and the desired value match exactly.

<> (Does Not Equal) - This operator requires that the system variable and the desired value do not match.

< (Less Than) - This operator requires that the value of the system variable be less than that of the desired value.

<= (Less Than or Equal To) - This operator requires that the value of the system variable be less than or equal to that of the desired value.

> (Greater Than) - This operator requires that the value of the system variable be greater than that of the desired value.

>= (Greater Than or Equal To) - This operator requires that the value of the system variable be greater than or equal to that of the desired value.

In - This option is primarily designed to match a value to a list of values. For instance, of the left side of the condition contains a user, and the right side of the condition contains user group, this operator will determine if the user is contained in the group. Similarly, if the value on the left is a string and the value on the right is a comma-separated list of values, the In operator means “in that list”. If the value is determined to be in the list of values, this operator will return "true"

Not In - This option is also primarily designed to match a value to a list of values, though, in this case, it returns "true" if the value is not in the list.

A User filter on a knowledge view will now support "user IN/NOT (group or user list)". If it is a "user IN group list", the filter will return True if the user is in ANY of the groups. If you have a "user NOT IN group list" filter, then the filter will return true if the user is NOT IN ANY of the groups.

Contains - The string value of the System Variable is contained in the string value of the desired value. For instance, a desired value of "Rejected" would contain a system variable with the string value of "Reject".

Does Not Contain - The string value of the System Variable is not contained in the string value of the desired value.

Matches - This operator works similarly to the Contains operator, but supports the ability to use AND and OR operators in the filter string. The filter string can also contain double quotes to force the search on that entire character string. If there is no operator between strings, or a ",", these will be treated as "AND". Additionally, the Matches operator supports a Regular Expression (REGEX) value for the desired value.

Desired or Comparison Value

Once the operator has been selected, you must provide the desired value on the right hand side of the Condition Row, to which the System Variable will be compared. The desired value can be derived from Process Director, or manually entered by the user. A dropdown menu is available to select the type of desired value.

image

If you select "String" as the desired value, a text box will be provided into which you can type the string value you desire.

image

In the example above, the condition requires that the value of the Text1 form field equal the desired string value, "Approved".

Managing Conditions

Once a condition has been created, you may remove a condition by selecting the red “x” next to the condition to be removed.

image

You may also select the green arrow icon to insert a new condition to be included in that condition.

image

You may also select the “Add Condition” button to insert another condition but to use it as an OR condition.

image

Once you have set your conditions for your option you can save it by clicking the “OK” or the “Update” buttons.

Meta Data Filter Criteria

The Meta Data Filter Criteria identifies what objects are available to this Knowledge View according to their category and attribute settings. Only objects that are assigned to the selected categories will be displayed in this Knowledge View. Additionally, conditional values can be specified for the category attributes to further limit matching objects.

Your categorization schema defines the category hierarchy and the optional attributes. For more information about the categorization schema refer to the chapter named Categorization in this document.

Categories - This contains a list of the categories that an object must belong to. If an object is not assigned to all of the categories specified it will not be displayed in this Knowledge View. To change the list of categories select the “Change Category Filter” button. A popup dialog will be displayed allowing you to choose from the category schema.

image

Attributes - This contains a list of all the attributes that are part of the selected categories. Every attribute of a selected category in displayed. Objects can be filtered using these attribute values. An object must match the attribute criteria to be listed in this Knowledge View. The filter value entered for the attribute must match the attribute type.

image

Object Information Filter Criteria

The Object Information Filter Criteria identifies what items are available to this Knowledge View according to their properties. Only items with matching conditional property values will be available to this Knowledge View.

image

Name - This will filter on a matching object name. The condition can be equals, not equal, or contains. This is a Text field type.

Description - This will filter on a matching object description. The condition can be equals, not equal, or contains. This is a Text field type.

Size - This will filter using the document size. The supported conditions are equals, not equal, less than and greater than. This is a Number field type.

File Type - This will filter on a matching document file extension (e.g. doc). The condition can be equals, not equal, or contains. This is a Text field type.

Create Time - This will filter on the create time for an object. The supported conditions are equals, not equal, less than, greater than, days less than and days greater than. This is a Date field type.

Update Time - This will filter on the last update time for an object. The supported conditions are equals, not equal, less than, greater than, days less than and days greater than. This is a Date field type.

Workflow Process Filter Criteria

The Object Information Filter Criteria identifies what items are available to this Knowledge View according to their properties. Only items with matching conditional property values will be available to this Knowledge View.

image

Priority - This will filter on the workflow priority. The supported conditions are equals, not equal, less than and greater than. This is a Number field type.

Workflow Definition - If this is selected then workflow definitions can be displayed in this Knowledge View.

Workflow User - This will filter on a matching workflow user. This will display any objects that were in the workflow package where this user participated in that workflow. The condition can be equals, not equal, or contains. This is a Text field type that contains a User ID.

Workflow Status - This will filter on objects where a workflow was run against them that currently have this workflow status. This will display the objects that are in the workflow package. The condition can be equals or not equal. This is a dropdown with the values Running and Completed.

Termination Reason - This will filter on objects that had workflow run against them that currently have this workflow termination status. The workflow must be completed and it will display the objects that are in the workflow package. The condition can be equals or not equal. This is a dropdown with the values Completed, Timed Out, Rejected, Did Not Finish, Failed, Cancelled, Skipped, and Approved.

Workflow User Status - This will filter on objects where a workflow was run against them and where the user identified in the Workflow User filter field has this status in the workflow. This will display the objects that are in the workflow package.

The condition can be equals or not equal. This is a dropdown with the values Running and Completed. This requires a user be specified in the Workflow User filter field.

Workflow User Term Reason - This will filter on objects where a workflow was run against them that where the user identified in the Workflow User filter field has this termination status in the workflow. The workflow must be completed and it will display the objects that are in the workflow package. The condition can be equals or not equal. This is a dropdown with the values Completed, Timed Out, Rejected, Did Not Finish, Failed, Cancelled, Skipped, and Approved. This requires a user be specified in the Workflow User filter field.

Form Filter Criteria

The Form Filter Criteria identifies what eForms are available to this Knowledge View according to specific form properties. Only forms with matching conditional property values will be available to this Knowledge View.

image

Form Text - This will filter on matching form field data filled out by a user. This will only match against the actual data entered, not the form field names. The condition can be equals, not equal, or contains. This is a Text field type.

Form Field - This will filter on form objects that have a matching form field name. This will match against the actual form field names in the definitions, but can still be used to return form data. The condition can be equals, not equal, or contains. This is a Text field type.

To create a Knowledge View that will match data for a specific form field add the Form Field name of the field and enter the Form Data (or prompt the user for form data).

Task Filter Criteria

image

The Workflow Task Filter Criteria identifies what workflow tasks are available to this Knowledge View according to specific workflow task properties. Only workflow tasks with matching conditional property values will be available to this Knowledge View.

Task Due Date

This will filter on task due date. This allows a Knowledge View to display workflow tasks that have an approaching due date. The supported conditions are equals, not equal, less than, greater than, days less than and days greater than. This is a Date field type.

Filter Conditions

The Knowledge View allows filtering on category attributes, form fields and object property fields. The supported field types include Text, Number, Yes/No, Dropdown, Currency, and Date fields. The filtering allows for a value and a conditional to be specified. Any type of search is case insensitive.

image

The supported conditionals are as follows:

equals - This conditional requires that the value entered match the property exactly.

not equal - This conditional requires that the value entered does not match the property exactly.

contains - This conditional requires that the value entered be contained within the property. For example, if the filter expression “Name contains Proj” is used in a Knowledge View, this will match objects with the names Process TimelineABC and My Process Timeline.

less than - This conditional will return matching items when the property is less than the value entered. This is supported for Number and Date field types only.

greater than - This conditional will return matching items when the property is greater than the value entered. This is supported for Number and Date field types only.

in - This conditional will return matching items when the property is in a group. This property is used for users and groups.

not in - This conditional will return matching items when the property is not in a group. This property is used for users and groups.

Filter Values

Filter values are what the Knowledge View is filtering on. These values are filtered against category attributes, eForm data and object property fields. The filter value entered for a category attribute or object property must match the type (e.g. Number). The filter value can also contain some of the system variables defined in the eForms chapter in the section named System Variables. For example, to configure a Knowledge View to only display forms the current user has submitted, set the Create User field to the current user system variable in the filter and only allow completed form data objects to be displayed. The system variable will be replaced with the User ID of the current user that is viewing the Knowledge View. Set the filter values in this textbox:

image

  • Was this article helpful?