Business rules are used to either insert, update or change field values contained within a Compleat transaction. Rules can be triggered at various stages of the transaction lifecycle i.e. On Creation, On Submission, and On Approval etc.
A business rule comprises three key elements: Business RuleDefines the field to be amended and the value it should contain., Rule CriteriaContains the conditions that determine when a rule should be triggered., and the Rule Profile.Defines which module and during which stage the criteria should be checked.
To create and apply a business rule you must create and configure each of these key elements in the following order:
When users raise a requisition for stationary, Compleat collects an additional analysis using the C Code – C10. This analysis asks the user if the goods are for internal, or external use (indicated by an internal or an external flag). If the user selects internal, Compleat updates an M2 Code (Accounting Segment) to contain the value 3003. However, if the user selects external, Compleat updates an M2 Code (Accounting Segment) to contain the value 4003 ( applies to Goods orders ONLY).
Therefore, to achieve this, we need to create two business rules:
- Rule 1 - to update an M2 Code to contain the value 3003 (for Goods orders – Internal).
- Rule 2 - to update an M2 Code to contain the value 4003 (for Goods orders – External).
- Select Business Rules > Business Rules.
- The Workflow Configuration > Business Rules page appears.
- Click .
- The Business Rule Configuration page appears.
- Enter the business rule description.
- Click .
- The 'Rule Options' page appears.
- (Optional) Select the Advanced Criteria 1 tab.
- (Optional) Select which additional criteria must be checked for this rule.
- (Optional) Enter the manual override.
- (Optional) Enter the range start criteria.
- (Optional) Enter the range end criteria.
- (Optional) Select the operator used for joining.
- (Optional) Select the Advanced Criteria 2 tab. See Advanced Criteria configuration fields.
NOTE: Advanced Criteria and Advanced Criteria 2 work using an OR operatoran OR operator returns the value if either or both Advanced Criteria are true, and returns false otherwise. . Therefore, if you use two advanced criteria, only one has to match for the rule to trigger.