Configuring business rules
Business rules automate actions that the application performs when certain conditions are met. You can create rules based on a combination of various conditions and actions.
You can create business rules that can add and modify data for records that belong to a few modules in Track-It!. You can automate actions, such as sending email notifications when a record is created, updated, or deleted based on field updates.
The following figure shows the process to configure a business rule:
This topic contains the following information:
- Overview of business rules
- Components of a business rule
- Key features and considerations
- Types of actions
- Supported expressions for configuring conditions and actions
- Out-of-the-box business rules
- Defining a business rule
- Prerequisites for executing a business rule
- Configuring advanced business rules
- Scenario: Define a business rule to update the priority of a ticket when the ticket is assigned John Smith
- Scenario: Define a business rule to send a notification to all technicians in a group
Overview of business rules
The following video (10:32) provides an overview of business rules in Track-It!:
Components of a business rule
Together, following components form a business rule:
Component | Description |
---|---|
Conditions | Determines the criteria after which a business rule is triggered. |
Actions | Defines the configured actions that the application performs after the business rule is triggered. |
Actions Schedule | Defines when the selected action must be performed. |
Key features and considerations
Note the following key features and considerations:
- Track-It! provides 20 out-of-the-box business rules. By default, these business rules, as well as any ones that you create, are inactive. You can activate a business rule by clearing the Inactive check box.
By default, a new business rule is inactive. You must clear the Inactive check box to activate a business rule. - While configuring an action, if you enter an incorrect or invalid expression, the notification content after the expression is truncated when an email notification is sent to users. Ensure that you use valid expressions in actions.
- If you configure multiple conditions, for a business rule with a combination of Created, Updated, and Deleted check boxes, the business rule is not executed when a record is deleted. However, if you configure multiple conditions for a business rule with only the Deleted checkbox selected, the business rule is executed as expected.
- Although the comparison conditions are available for a text type field, BMC recommends that you do not use these conditions to configure a condition for a text type field.
- You can enter a custom value for the Select/Enter a Value list. The Select/Enter a Value list also supports expressions and already created records for the field selected in the Select a Field list.
- You can schedule a business rule to run immediately or at a later time. If a business rule is scheduled to run at a later time, you can specify the date and time expression to run the rule. You can also schedule a business rule to run repeatedly and you can define the number of repetitions that the rule must be run.
- Use the curly brackets ({) in a text field type fields, such as Email body, to access the list of available expressions for conditions and actions.
- When a business rule with the create/update action is executed, a system note is added to the record.
For example, if a business rule is executed on a ticket to update the Priority field, a system note named BR_businessruleName is added to the ticket notes. - You can copy paste the rich text field (RTF) content to the email notification editor. It is not displayed as expected in the Track-It! application, but the content is displayed as expected in the email notification that is sent to the users.
- If you restart the IIS server, the job monitor and the email services for business rules stop. You must restart these services manually.
- If you configure a business rule to update a ticket by updating or creating a new ticket, ensure that you configure the appropriate conditions so the business rule does not run into an infinite loop.
- Attachments with file name exceeding 150 characters will not be attached through Business Rules configured for Incoming emails.
Types of actions
The following actions are available for configuring business rules:
Supported expressions for configuring conditions and actions
You can use expressions to configure conditions and actions for delete business rules. The following table provides information about the supported expressions for configuring actions:
Out-of-the-box business rules
The following table provides information about the out-of-the-box business rules in Track-It!:
Defining a business rule
Perform the following steps to define a business rule:
- On the header bar, expand the hamburger menu
and select Configuration.
- Click SLAs and Business Rules and then click Business Rules.
- On the Business Rules page, click New.
- In the Add Business Rule dialog box, in the Business Rule Name field, enter a name.
- To activate the business rule, clear the Inactive check box.
- In the Business Rule Description field, enter a brief description about the business rule.
- In the Define Conditions section, perform the following actions:
- From the When list, select an appropriate option, such as Ticket.
- Based on the business rule that you want to configure, select one or more of the following check boxes:
- Created
- Updated
- Deleted
- From the Select a Field list, select a field that you want to use to configure the business rule, such as Status.
- From the Select a Condition list, select a required condition.
- Based on the condition that you select, from the Select/Enter a Value list, select or enter a field value.
You can enter a custom value; use { to access the list of expressions, or select an already created value from the list. - To add the defined condition, click
.
- (Optional) To add another condition, repeat step 6a to step 6f.
- (Optional) To delete a condition, click
.
- Click the Define Actions section and perform the following actions:
- From the Select an Action list, select an appropriate action that the business rule must perform, such as Create Record.
- Based on the value that you select in the Select an Action list, you can configure the action that the business rule must complete.
- To add configured action, click
.
- (Optional) To add multiple actions, repeat step 7a to step 7c.
- (Optional) To delete an action, click
.
- Click the Define Actions Schedule section, perform the following actions:
- For the When to perform the actions setting, select an appropriate option:
- Immediately
- At a later time
- If you select the At a later time option, perform the following actions:
- Set the time at which you want to run the business rule.
For example, 2 hours After the Open Date. - To set a recurrence for the business rule, in the Repeat field, enter a value and set the duration.
- Set the time at which you want to run the business rule.
- From the Time Zone list, select a preferred time zone in which you want to run the business rule.
- From the Work Schedule list, select a work schedule.
- For the When to perform the actions setting, select an appropriate option:
- Click Save.
Prerequisites for executing a business rule
To ensure that the defined business rules are executed, the following prerequisites must be met:
- Ensure that the Job Monitor service is running.
- Configure the Email settings. For more information, see Configuring emails.
- If you are using the SMTP protocol, ensure that the SMTP service is running.
- To execute the Business rules with the send notification with details action, the email service must be running.
Configuring advanced business rules
The following video (16:22) provides information about configuring advanced business rules in Track-It!:
Scenario: Define a business rule to update the priority of a ticket when the ticket is assigned John Smith
Perform the following steps:
- On the header bar, expand the hamburger menu
and select Configuration.
- Click SLAs and Business Rules and then click Business Rules.
- On the Business Rules page, click New.
- In the Add Business Rule dialog box, in the Business Rule Name field, enter Assign and send notification to John Smith when a ticket with critical priority is created.
- Clear the Inactive check box.
- In the Business Rule Description field, enter When the defined conditions are met, assign the matching tickets and send email notification to technician John Smith..
- In the Define Conditions section, perform the following actions:
- From the When list, select Ticket and then select the Created check box.
- From the select a Field list, select Priority.
- From the Select a Condition list, select equals.
- From the Select/Enter a Value list, select 1 - Critical.
- Click
.
- Click the Define Actions section and perform the following actions:
- From the Select an Action list, select Update Record.
- From the Select Record Type list, Select Update Ticket Values.
- Click the Select/Edit fields.
- In the Select a Field dialog box, from the Select a Field list, select Ticket ID.
- From the Select a Value from list, select Use a value from current record.
- From the Select/Enter a Value list, select {Ticket - Ticket ID}.
- Click
.
- In the Select a Field dialog box, from the Select a Field list, select Assigned To Technician.
- From the Select a Value from list, select Use a value or an expression.
- From the Select/Enter a Value list, select John.
- Click Apply.
- Click the Define Actions Schedule section, perform the following actions:
- For the When to perform the action(s) setting, select the At a later time option.
- In the Hour(s) field, enter 1.
- Select the After option and from the next list, select Last Modified.
- In the Repeat field, enter 1.
- In the Hour(s) field next to the Repeat field, enter 1.
- From the Time Zone list, select (GMT-06:00) Central Time (US & Canada).
- From the Work Schedule list, select 40-hour work week.
- Click Save.
Scenario: Define a business rule to send a notification to all technicians in a group
Perform the following steps:
- On the header bar, expand the hamburger menu
and select Configuration.
- Click SLAs and Business Rules and then click Business Rules.
- On the Business Rules page, click New.
- In the Add Business Rule dialog box, in the Business Rule Name field, enter Notify technicians about a ticket creation or an update with multiple conditions.
- Clear the Inactive check box.
- In the Business Rule Description field, enter Notify technician that ticket is created or updated with multiple conditions with Critical priority and Operating Systems..
- In the Define Conditions section, perform the following actions:
- From the When list, select Ticket and then select the Created and Updated check boxes.
- From the Select a Field list, select Category.
- From the Select a Condition list, select equals.
- From the Select/Enter a Value list, select Operating System.
- Click
.
- To add the next condition, from the Select a Field list, select Priority.
- From the Select a Condition list, select equals.
- From the Select/Enter a Value list, select 1 - Critical.
- Click
.
- To add the next condition, from the Select a Field list, select Ticket Summary.
- From the Select a Condition list, select is not blank.
- Click
.
- Click the Define Actions section and perform the following actions:
- From the Select an Action list, select Send Notification.
- Click Notification Details.
- In the To section, perform one or more of the following actions:
- From the Select Group list, select {Ticket - Group}.
- At CC, select {Ticket - Cc} or enter email addresses.
- At BCC, select {Ticket - Bcc} or enter email addresses.
- In the Subject field, enter Ticket with {Ticket – Ticket ID} - {Ticket - Ticket Summary} has been created.
- Click Apply.
- Click
.
- Click the Define Actions Schedule section and for the When to perform the action(s) setting, select the Immediately option.
- Click Save.
This section contains the following topics: