Override Engine Setup
Prerequisites
-
Read the following article before you set up the Override Engine for the first time:
-
To set up the Override Engine, you need the following licenses:
-
To set up the Override Engine, you must:
-
To set up the Override Engine, you need:
-
System permissions:
-
Customize Application
-
Manage Profiles and Permission Sets
-
View Setup and Configuration
-
Basics
-
The Override Engine can update the price or cost of quote items, ticket items, and/or invoice items based on criteria.
-
You can also configure the Override Engine to update fields other than those for prices/costs.
-
-
When a price/cost override applies to an item, the item’s price/cost changes automatically and you can’t change it manually.
-
An Override Configuration defines the rules that determine whether an Override should apply.
Override configurations are defined in the Admin Portal.
-
An Override defines the value to use when an Override Configuration applies.
Override values are defined in the Overrides tab in Back Office.
Guidelines
Override Configurations
Records Updated by Overrides
-
The Applies to SObject field controls the records updated by overrides.
-
You can apply overrides to quote items, ticket items, or invoice items.
Fields Updated by Overrides
-
Enter the field(s) to update in Override Fields.
-
You must enter the API name of the field(s) to which overrides apply.
Enter the API names of fields with each value separated by a comma.
-
The field(s) you enter must exist on the Override object and the relevant item object.
Enter
FX5__Price__c
to apply overrides to the Price field on ticket items. -
You can use custom fields if you want to define your own overrides.
Custom fields for override criteria must have the same API name on both the Override and item object(s).
Override Criteria
The Filter Clause field contains the criteria that triggers overrides if a record meets the criteria.
You can set up overrides for any quote item, ticket item, or invoice item field. |
Override criteria maps fields on the Override object to fields on the object to which overrides apply.
Consider the following example:
FX5__CustomerAccount__c==$FX5__CustomerAccount__c
-
The first field is the Customer Account field on the Override object.
-
The second field is the Customer Account field on the object to which overrides apply.
-
You must separate the fields with a $ sign.
Use the &&
function to require items to match an override in all of the specified fields.
(FX5__Catalog_Item__c==$FX5__Catalog_Item__c) && (FX5__CustomerAccount__c==$FX5__CustomerAccount__c)
AND is also supported, but && is preferred. Lower case letters in the operator, such as and , are not supported.
|
Use the ||
function to require items to match an override in any of the specified fields.
(FX5__Catalog_Item__c==null || FX5__Catalog_Item__c==$FX5__Catalog_Item__c) && (FX5__CustomerAccount__c==null || FX5__CustomerAccount__c==$FX5__CustomerAccount__c)
OR is also supported, but || is preferred. Lower case letters in the operator, such as or , are not supported.
|
Handling Multiple Overrides
-
Sometimes there are multiple overrides applicable to an item.
-
To handle this, you must add logic to decide which override to use.
-
Complete the following fields to handle multiple overrides:
Field | Description |
---|---|
Sort Clause |
Enter the sort order of applicable overrides.
|
Enter |
|
Limit |
Enter the number of overrides to consider.
|
InAggregation |
Select if you enter |
Overriding values with null values
-
Select the Apply Null checkbox to override field values in items with null values.
-
This feature can be useful in situations where you want to clear the value entered in a field when an item meets certain criteria.
Overrides
Override Criteria
-
You can set up overrides for any quote item, ticket item, or invoice item field.
-
Override criteria maps fields on the Override object to fields on the relevant item object(s).
-
Consider the following example:
FX5__CustomerAccount__c==$FX5__CustomerAccount__c
-
This override criteria maps the Customer field on the Override object to the Customer field on ticket items.
-
-
Out of the box, you can use the Catalog Item, Customer, and Office fields in override criteria.
These fields are managed fields on the Override, Quote Item, Ticket Item, and Invoice Item objects.
-
You can also use custom fields for override criteria as long as they have the same API name on both the Override and item object(s).
-
You can use custom fields if you want to define your own overrides.
Date Ranges
You can make overrides apply within a specific date range.
To set a date range for overrides, enter dates in the Effective Date and Expiration Date fields.
The Quote or Ticket’s Date field must be greater than or equal to the Override’s Effective Date and less than or equal to the Override’s Expiration Date. |
Considerations
-
When a price/cost override applies to an item, the item’s price/cost stays locked and you can’t change it manually.
-
When you add a new price/cost override:
-
The override won’t apply to items added before that date.
-
The override will apply to items added after that date.
-
-
When you update a price/cost override:
-
The previous version of the override will apply to items added before that date.
-
The new version of the override will apply to items added after that date.
-
Price Overrides
Example 1: Adding Price Overrides Based on Customer
Scenario
In this example, we will add price overrides based on the customer.
Once we set up the overrides:
-
The prices of quote items will change based on the customer selected for quote items.
-
The prices of ticket items will change based on the customer selected for ticket items.
Setup Instructions
-
Add an override configuration:
-
Open the Override Configs tab
-
Click New
-
Complete the following:
-
In Name, enter "Price Override by Customer"
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
In Override Fields, enter
FX5__Price__c
This entry maps the Price field on overrides to the Price field on quote items and ticket items.
-
In Override Type, select "Price"
-
In Filter Clause, enter the following:
FX5__CustomerAccount__c==$FX5__CustomerAccount__c && FX5__Catalog_Item__c==$FX5__Catalog_Item__c
This entry ensures that overrides apply to quote items and ticket items with a matching customer.
-
In Active, select the checkbox
-
In Limit, enter "1"
-
In Sort Clause, enter
FX5__CustomerAccount__c
This entry sorts matching items by customer.
-
-
Click Save
-
-
Add overrides for each customer:
-
Open the Overrides tab
-
Click New
-
Complete the following:
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
In Customer, select a customer
-
In Catalog Item, select the catalog item for which to apply the override
The override applies to all quote items and ticket items linked to the catalog item through a price book item.
-
In Override Type, select "Price"
-
In Price, enter the price to charge the customer
-
(Optional) In Effective Date, enter the date when the override should start being used
-
(Optional) In Expiration Date, enter the date when the override should stop being used
An override that does not have an Expiration Date always applies unless its Override Config is deactivated.
-
-
Click Save & New
-
Repeat steps c and d
-
-
Apply the override configuration to price book items:
-
Open the Price Book Items tab
-
Open a price book item for a catalog item to which overrides apply.
-
Click Edit
-
In Override Price Method, select "Price Override by Customer"
-
Click Save
-
Repeat steps b to e
-
Example 2: Adding Price Overrides Based on QUANTITY
Scenario
In this example, we will add price overrides based on a quantity. More specifically, the price override will be based on well depth.
Once we set up the overrides:
-
The prices of quote items will change based on the well depth selected for quote items.
-
The prices of ticket items will change based on the well depth selected for ticket items.
Setup Instructions
-
If not already created in your Org, create the following custom fields:
-
WellDepthc field on Ticketc
-
TicketWellDepthc field on Ticket_Itemc as the following formula:
FX5__Ticket__r.WellDepth__c
-
MinDepthc and MaxDepthc on Overrider__c
-
-
If not already included, ensure the following fields are included on the specified page layouts:
-
IsAggregation, Sort Clause, and Limit on the Override Configs page layout
-
MinDepth, MaxDepth, and Price on the Overrides page layout
-
Override Price Method on the Price Book Item page layout
-
-
Add an override configuration:
-
Open the Override Configs tab
-
Click New
-
Enter "Price Override by Well Depth" in Name
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
Enter "FX5Pricec" in Override Fields
-
Select "Price" in Override Type to map the Price field on overrides to the Price field on quote items and ticket items
-
Enter the following formula in Filter Clause:
FX5__CustomerAccount__c==$FX5__CustomerAccount__c && FX5__Catalog_Item__c==$FX5__Catalog_Item__c
-
Enter "1" in Limit
-
Enter "WellDepth__c" in Sort Clause to sort matching items by well depth
-
Click Save
Figure 1. Override Config settings for well depth override example
-
-
Add the overrides:
-
Open the Overrides tab
-
Click New
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
Enter "50" to MinDepth
-
Enter "500" to MaxDepth
-
Enter "100" to Price
-
Click Save & New
Figure 2. Entries in the setup screen for well depth override
-
-
Repeat steps c–g with "500" to MinDepth, "599" in MaxDepth, and "200" in Price
-
Repeat steps c–f with "600" to MinDepth, "699" in MaxDepth, and "300" in Price
-
Click Save
-
Edit Price Book Item Detail
-
Select "Price Override by Well Depth" in Override Price Method
-
Click Save
Figure 3. Price book item detail showing the override selected
Cost Overrides
Example 1: Adding Cost Overrides Based on Location
Scenario
In this example, we will add cost overrides based on the office.
Once we set up the overrides:
-
The cost of quote items will change based on the office selected for quote items.
-
The cost of ticket items will change based on the office selected for ticket items.
Setup Instructions
-
Add an override configuration:
-
Open the Override Configs tab
-
Click New
-
Complete the following:
-
In Name, enter "Cost Override by Office"
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
In Override Fields, enter "FX5__Cost__c"
This entry maps the Cost field on overrides to the Cost field on quote items and ticket items. -
In Override Type, select "Cost"
-
In Filter Clause, enter the following
FX5__Office__c==$FX5__Office__c && FX5__Catalog_Item__c==$FX5__Catalog_Item__c
This entry ensures that overrides apply to quote items and ticket items with a matching office. -
In Limit, enter "1"
-
In Sort Clause, enter "FX5__Office__c"
This entry sorts matching items by office. -
Click Save
-
-
-
Add overrides for each office:
-
Open the Overrides tab
-
Click New
-
Complete the following:
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
In Office, select an office
-
In Catalog Item, select the catalog item for which to apply the override TIP: The override applies to all quote items and ticket items linked to the catalog item through a price book item.
-
In Override Type, select "Cost"
-
In Cost, enter the cost for the office
-
Select IsActive
-
(Optional) Set the date range in which to apply the override
-
-
Click Save & New
-
Repeat steps c and d for other offices as needed
-
-
Apply the override configuration to price book items:
-
Open the Price Book Items tab
-
Open a price book item for a catalog item to which overrides apply
-
Click Edit
-
In Override Cost Method, select "Cost Override by Office"
-
Click Save
-
Repeat steps b to e for other price book items as needed
-
Price & Cost Overrides
Example 1: Adding Price & Cost Overrides Based on Treatment Facility
Scenario
In this example, we will add price and cost overrides based on the treatment facility.
Once we set up the overrides:
-
The prices and costs of quote items will change based on the treatment facility selected for quote items.
-
The prices and costs of ticket items will change based on the treatment facility selected for ticket items.
Setup Instructions
-
Add a Treatment Facility (Treatment_Facility__c) picklist to the following objects:
-
Quote Item
-
Ticket Item
-
Override
-
-
Add an override configuration:
-
Open the Override Configs tab
-
Click New
-
Complete the following:
-
In Name, enter "Price & Cost Overrides by Treatment Facility"
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
In Override Fields, enter "FX5__Cost__c, FX5__Price__c"
This entry maps the Cost and Price fields on overrides to the Cost and Price fields on quote items and ticket items. -
In Override Type, select "Price"
-
In Filter Clause, enter the following:
(Treatment_Facility__c==$Treatment_Facility__c) && (FX5__Catalog_Item__c==null || FX5__Catalog_Item__c==$FX5__Catalog_Item__c)
This entry ensures that overrides apply to items with a matching treatment facility.
The advanced logic for catalog items in this example ensures that items with a matching treatment facility can have a matching catalog item or a null value entered for their catalog item.
-
In Limit, enter "1"
-
In Sort Clause, enter "Treatment_Facility__c, FX5__Catalog_Item__c NULLS LAST".
This entry sorts matching items so that those with a matching treatment facility and catalog item are listed first. -
Click Save
-
-
-
Add overrides for each treatment facility:
-
Open the Overrides tab
-
Click New
-
Complete the following:
-
In Applies to SObject, add "Ticket" and "Quote" to Chosen
-
In Treatment Facility, select a treatment facility
-
In Catalog Item, select the catalog item for which to apply the override TIP: The override applies to all quote items and ticket items linked to the catalog item through a price book item.
-
In Override Type, select "Price"
-
In Price, enter the price to charge for using the treatment facility
-
In Cost, enter the cost for using the treatment facility
-
Select IsActive
-
(Optional) Set the date range in which to apply the override
-
-
Click Save & New
-
Repeat steps c and d for other treatment facilities
-
-
Apply the override configuration to price book items:
-
Open the Price Book Items tab
-
Open a price book item for a catalog item to which overrides apply
-
Click Edit
-
In Override Price Method, select "Price & Cost Overrides by Treatment Facility"
-
Click Save
-
Repeat steps b to e for other price book items as needed
-