Template rules automatically set or suggest the setting of one or more parameter values. The trigger for a rule is defined by one or more parameters having certain values. By making a template rule forced the values that are set by the rule cannot be unset as long as the triggering condition remains.
Definition of trigger and actions
A template rule contains a trigger and one or more actions.
The trigger is defined by first selecting which parameters that shall be included and then for each parameter select the values that shall trigger the rule. In the case of multi choice parameters it's the multi choice values that are selected to participate in the trigger rather than the actual parameters. A template rule is triggered when all Trigger parameters have been set to one of their triggering values.
See Disallowed combination rules for how triggering values are defined for different types of parameters.
For lookup parameters it's possible to define the non-triggering values instead of the triggering values. This is done by selecting the option Check non-triggering values. Then those values that are not selected are the triggering values and new values that are added to the parameter becomes triggering by default.
The actions are defined on the tab Template parameters as parameters and/or multi choice values that each are set to specific values.
Clearing out values of parameters
A template rule cannot only set values of parameters it can also clear out parameter's values which means setting their values to null. This is done by selecting the parameter on the tab Template parameters but without giving it a value. For Boolean parameters and multi choice values indeterminate is the null value, i.e. neither true nor false.
Behavior settings
Template rules have settings that control their behavior:
Setting name |
Description |
---|---|
Show confirm box |
A confirmation box is shown to the user and parameter values are only set by the rule if the user confirms the changes. |
Show information box |
An information box is shown to the user explaining what changes will be done. |
Forced template values |
Parameter values that are set by the rule get locked and cannot be unset by the user as long as the triggering condition remains. This setting cannot be combined with Show confirm box. |
Restore previous value |
Parameter values that are set by the rule are restored to their previous values if the triggering condition ends. This only applies if the rule was triggered and untriggered during the same user session. |
Read also about site effectivity for rules.
Forced template rules can make triggering values disallowed
If one or more values that shall be forcefully set by a template rule cannot be set due to other rules the template rules must not be triggered. Combinum solves this by disabling the triggering values if the template rule is one value away from being triggered. Read more about conflict resolution between rules.