- 22 Nov 2024
- 9 Minutes to read
- Print
- DarkLight
Define conditional triggers
- Updated on 22 Nov 2024
- 9 Minutes to read
- Print
- DarkLight
Conditional triggers are rules that execute when their defined conditions are met. These triggers are configured per product knowledge base. The different types of conditional triggers include:
- Trigger Assign DA Value
- Trigger Assign DA Default Value
- Trigger Copy Attribute Values
- Trigger Change DA Meta Attribute (meta attributes control the visibility, editability, or mandatory status of an attribute)
- Trigger Assign Business Type
- Trigger Product Recommendation
- Validation Trigger
These triggers are part of the configuration engine and primarily work on the configuration of a line item.
A common use case is setting the value of one dynamic attribute based on the value of another, or modifying the visibility, editability, or mandatory status of an attribute depending on another DA's value. This functionality can be achieved using Trigger Assign DA Value, Trigger Assign DA Default Value, and Trigger Change DA Meta Attribute.
Another use case involves product recommendations, where the Trigger Product Recommendation suggests additional products for up-sell or cross-sell opportunities.
The execution sequence of triggers is managed first by the group they belong to, and then by their order within the group.
Define a conditional trigger from the UI
Prerequisites
To define a trigger, your product must have:
Procedure
From the application left navigation area, select Products.
Select a product.
From the top navigation bar, select Knowledge Base.
Select a knowledge base.
On the Triggers tab, select to define a new trigger group.
On the New Trigger Group dialog, enter information or make selections:
- Name—Enter a name for the trigger group.
- Type—Select Conditional.
Select Create.
Select the trigger group from the list.
On the Attributes sub-tab, select , select attributes to add to the trigger group, then select Add.
On the Triggers sub-tab, select to create a trigger.
Select the trigger.
On the Conditions tab, select to create a condition. In the new row, enter information or make selections:
Name—Enter the name for the condition.
Search Expression—Enter the search expression (a query) to obtain the dynamic attribute value or URI. For example, enter
SalesItem().getDAValue('DDA')[0]
to get the dynamic attribute value orSalesItem().getDAUri(‘DDA’)[0]
to get the dynamic attribute URI.Alternatively, select to open the list of dynamic attributes, then select an attribute from the list.
Operator—Select an operator.
Condition Value—Enter a literal value (for example, 1 or true) or select to select a value from the attribute's ranges.
On the Actions tab, select , select the needed trigger type, and then select Create.
Create a knowledge base snapshot to apply the trigger.
Explore the following sections for configuration details for specific conditional trigger types.
Trigger Assign DA Value
Use this trigger to assign a value to a dynamic attribute (DA) that cannot be changed by the user. To define this trigger, follow these steps with specific instructions as follows:
At Step 13, on the Actions tab, select , select Trigger Assign DA Value, and then select Create.
Available actions appear in the list.In the needed action row, proceed based on the Attribute column value.
If the value is toSearchExpression, in the Expression Based Value column, enter a search expression (a query) to obtain the DA to be assigned or select to select a DA from the list of options.
toSearchExpression means the target attribute to which the value will be assigned. The target attribute must be the starting object (for example, the sales item triggering the action).
If the value is toSearchExpressionValue / toValue, define one of the following columns:
- In the Literal Value column, enter a literal value or select to select a value from the attribute's ranges.
- In the Expression Based Value column, enter a search expression to obtain a value to be assigned, or select to select a value from the list of options.
Trigger Assign DA Default Value
The trigger assigns a value to a dynamic attribute (DA) if the specified conditions are met. However, unlike in the Trigger Assign DA Value case, the assigned value is editable by the user. If the user deletes the value they assigned, the default value (the trigger-assigned value) is reapplied.
The steps to configure Trigger Assign DA Default Value are the same as those for configuring Trigger Assign DA Value. The only difference is selecting Trigger Assign DA Default Value during the action creation process.
Trigger Change DA Meta Attribute
The trigger changes the DA’s meta attribute value. Use this trigger to control the visibility, editability, or mandatory status of an attribute. The trigger executes if all its conditions are met.
To define this trigger, follow these steps with specific instructions as follows:
At Step 13, on the Actions tab, select , select Trigger Change DA Meta Attribute, and then select Create.
Available actions appear in the list.In the needed action row, proceed based on the Attribute column value.
- If the value is toSearchExpression, in the Expression Based Value column, enter a search expression to obtain the DA to be assigned or select to select a DA from the list of options.
- If the value is toAttribute, in the Literal Value column, define the target attribute.
- If the value is toBooleanValue, in the Literal Value column, set the switch to YES or NO to assign the Boolean value.
Trigger Copy Attribute Value
This trigger copies the value of a dynamic attribute (DA) from a configuration or config item of a sales item and makes it available at the sales item level. It can be used to map assigned, calculated, or system-derived values from a configuration (config item) to the sales item level. For example, it can change the sales item's name based on a DA value or adjust the quantity of the sales item and its children based on a DA value.
However, note that this trigger cannot update child items if they do not yet exist through the parent’s trigger.
To define this trigger, follow these steps with specific instructions as follows:
At Step 13, on the Actions tab, select , select Trigger Copy Attribute Value, and then select Create.
Available actions appear in the list.In the needed action row, proceed based on the Attribute column value.
- If the value is fromSearchExpression, in the Expression Based Value column, enter a search expression to obtain the DA whose value you want to copy or select to select a DA from the list of options.
- If the value is toSearchExpression, in the Expression Based Value column, enter a search expression to obtain the target DA into which to paste the value or select to select a DA from the list of options.
- If the value is toAttribute, in the Literal Value column, define the target attribute (for example, http://www.inmindcloud.com/application/schema.owl#objectName%29)
Trigger Product Recommendation
This trigger facilitates up-selling and cross-selling insights. It allows a specific product to be recommended for a given line item. The recommended products can then be added as subline items.
To define this trigger, follow these steps with specific instructions as follows:
- At Step 13, on the Actions tab, select , select Trigger Product Recommendation, and then select Create.
Available actions appear in the list. - In the needed action row, in the Literal Value column, define the value for the attribute key. Use
,
as a separator for multiple values (for example, EASY400A,803).
Validation Trigger
This trigger helps to validate configuration attributes of a sales item based on the defined conditions. It sends the predefined validation message to users as a notification.
To define this trigger, follow these steps with specific instructions as follows:
At Step 13, on the Actions tab, select , select Trigger Product Recommendation, and then select Create.
Available actions appear in the list.In the needed action row, proceed based on the Attribute column value.
If the value is messageType, in the Literal Values column, enter the message type.
If the value is validationMessage, in the Literal Values column, enter the label key in the message.properties file. For example, trigger.validation.general.max.threshold = {0}:{1}->{2}. Value exceeds the maximum threshold. Where {0} is the item’s position, {1} is the sales item name, {2} is the trigger name.
NoteThe parameters {0}, {1}, {2} are fixed in the code to show the item position, sales item name and the trigger name to the user.
This trigger will be triggered after saving the line items.
- The label key will be displayed if it is not found in the message.properties.
- To open the message.properties file, go to CMIS localization > ui-customization folder.
Define a conditional trigger from the knowledge base Excel spreadsheet
Prerequisites
To define a trigger, your product must have:
Procedure
Use one of these methods to define a conditional trigger from the Excel spreadsheet:
Define a standard conditional trigger
The standard conditional rule is primarily designed for advanced users familiar with IMCScript syntax. Users must write the IMCScript syntax in the Conditions and Actions properties.
- Download a product knowledge base.
On the Download Options dialog, on the Trigger Groups tab, select a checkbox next to Conditional and in the No. of Sheet(s) column specify the number of range trigger groups. - In the downloaded file, on the new trigger group sheet with the RULE_X name, define conditions and actions. Depending on the selected action type, the corresponding action cells will be highlighted for the modeler to specify the actions.Note
Details of the action value, based on the action type, can be found in the _ConditionalTriggersMasterData sheet.
- In Zilliant CPQ, select and then select the filled out spreadsheet to upload.
- Confirm the upload.
- Create a knowledge base snapshot to apply the trigger.
Define a simplified conditional trigger
The simplified conditional trigger is designed for straightforward use cases where a product modeler wants to define a simple condition, such as: if [DA1] value is EQUAL TO [Value 1], then assign [DA2] value to [Value 2]. This feature is exclusively available through Excel spreadsheet.
Download a product knowledge base.
On the Download Options dialog, on the Trigger Groups tab, select a checkbox next to Conditional Simple (using direct names and values) and in the No. of Sheet(s) column specify the number of range trigger groups.In the downloaded file, on the RULE_X (where X is the trigger group sequence number) sheet, define information about the trigger group:
- Name—Enter a name for the trigger group.
- Sequence ID—Enter the trigger group's sequence ID. This ID helps to maintain the order of sheets inside the knowledge base spreadsheet when a user downloads it again.
Select the attribute name and attribute value as a condition.
Select the action type. Available types:
- ASSIGN_DA_VALUE
- ASSIGN_DA_DEFAULT_VALUE
- HIDE_ATTRIBUTE
- SHOW_ATTRIBUTE
- MARK_READ_ONLY
- MARK_MANDATORY
- MARK_PRICING_RELEVANT
- UNMARK_READ_ONLY
- UNMARK_MANDATORY
- UNMARK_PRICING_RELEVANT
Depending on the action type, a product modeler can select the TO ATTRIBUTE NAME and TO ATTRIBUTE LITERAL VALUE options.
In Zilliant CPQ, select and then select the filled out spreadsheet to upload.
Confirm the upload.
Create a knowledge base snapshot to apply the trigger.
The EQUAL operator is only supported for simple conditional triggers, and the assignment of a DA value must be done using a range value. Assigning a DA value derived from another DA is not supported. To handle such cases, the standard conditional trigger sheet must be used, as it provides advanced features through the IMCScript capability.