This article describes the zQuoteRulesEngine class that is used to implement a rules engine in Zuora Quotes.
The zQuoteRulesEngine class includes the following properties.
|PRICE_FIELD_DISCOUNT||String||Name of the discount field|
|PRICE_FIELD_EFFECTIVE_PRICE||String||Name of the effective price field|
|PRICE_FIELD_QUANTITY||String||Name of the quantity field|
|PRICE_FIELD_TOTAL||String||Name of the total field|
|PRODUCT_RULE_TYPE_ADDED_DISABLED||String||Name of the field that indicates whether Add is enabled|
|PRODUCT_RULE_TYPE_ADDED_ENABLED||String||Name of the field that indicates whether Add is disabled|
|PRODUCT_RULE_TYPE_REMOVED_ENABLED||String||Name of the field that indicates whether a product can be removed when a rule applies|
|UPDATABLE_FIELD_INCLUDED_UNITS||String||Name of the included units field|
The zQuoteRulesEngine class includes the ChangeLog class you use to record changes as product or price rules are applied during quoting.
The ChangeLog class contains the following property:
String description: Holds the log text.
The zQuoteRulesEngine class provides the Quote Rules Engine plugin interface. Use the plugin to implement custom quoting rules on prices or products.
The plugin interface is defined as global ZQuoteRulesEngine.QuoteRulesEnginePlugin and contains the following interface methods:
See Quote Rules Engine Plugin Example for a sample rules engine plugin code.