Override Engine Setup
Introduction
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. See Override Configurations guidelines for things to keep in mind. |
An Override defines the value to use when an Override Configuration applies.
Override values are defined in the Overrides tab in Back Office. |
You can apply overrides for:
Prerequisites
To setup and use the Override Engine, you need to:
Have these user licenses | Have these permissions | Complete these tasks and review these topics before continuing |
---|---|---|
|
Guidelines
This section offers guidelines for Override Configurations, Overriding values with null values and Overrides.
Override Configurations
Override configurations are divided into Records Updated by Overrides, Fields Updated by Overrides, Override Criteria, and Handling Multiple Overrides.
Records Updated by Overrides
To control the records updated by overrides, use the Applies to SObject field.
You can apply overrides to quote items, ticket items, or invoice items.
Fields Updated by Overrides
To override a field, enter the field(s) in Override Fields.
Enter the API name of the field(s) to which overrides apply. |
When entering the field API names, separate each value 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.
If you want to define your own overrides, you can use custom fields.
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. |
The 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.
To require items to match an override in all of the specified fields, use the &&
function.
(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.
|
To require items match an override in any of the specified fields, use the ||
function .
(FX5__Catalog_Item__c==null || FX5__Catalog_Item__c==$FX5__Catalog_Item__c) && (FX5__CustomerAccount__c==null || FX5__CustomerAccount__c==$FX5__CustomerAccount__c)
Use || instead of OR (although it is supported). Lower case letters in the operator, such as or , are not supported.
|
Handling Multiple Overrides
You can apply multiple overrides 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.
Use the checkbox in situations where you want to clear the value entered in a field when an item meets certain criteria.
Overrides
You can specify the criteria for an override or override a date range.
Override Criteria
You can set up overrides for any quote item, ticket item, or invoice item field. The Override Criteria maps fields on the Override object to fields on the relevant item object(s).
In this 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.
You can use the Catalog Item, Customer, and Office fields in override criteria right away.
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).
If you want to define your own overrides, use custom fields.
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
|
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: |
|
When you update a price/cost override: |
|
Price Overrides
When using price overrides, these examples show adding price overrides based on a customer and adding price overrides based on quantity.
Example 1: Adding 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:
Name
Enter "Price Override by Customer"
Applies to SObject
Add "Ticket" and "Quote" to Chosen
Override Fields
Enter
FX5__Price__c
This entry maps the Price field on overrides to the Price field on quote items and ticket items.
Override Type
Select "Price"
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.
Active
Select the checkbox.
Limit
enter
1
.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:
Applies to SObject
Add "Ticket" and "Quote" to Chosen
Customer
Select a customer.
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.
Override Type
Select "Price".
Price
Enter the price to charge the customer.
(Optional)
Effective DateEnter the date when the override should start being used.
(Optional)
Expiration DateEnter 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 these steps for other customers.
-
-
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 these steps for other price books.
-
Example 2: Adding 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:
include:eticketing:partial$nosimsamenames.adoc[]
Object Custom Fields Ticket__c
WellDepth__c
Ticket_Item__c
TicketWellDepth__c - use the following formula:
FX5__Ticket__r.WellDepth__c
Overrider__c
MinDepth__c
MaxDepth__c -
If not already included, ensure the following fields are included on the specified page layouts:
Page Layout Fields Override Configs
IsAggregation
Sort Clause
LimitOverrides
MinDepth
MaxDepth
PricePrice Book Item
Override Price Method
Override Configs
IsAggregation
Sort Clause
LimitOverrides
MinDepth
MaxDepth
PricePrice Book Item
Override Price Method
-
Add an override configuration:
-
Open the Override Configs tab.
-
Click New.
-
Complete the following entries:
Field Enter or Select Name
Price Override by Well Depth
Applies to SObject
Add "Ticket" and "Quote" to Chosen
Override Fields
FX5__Price__c
Override Type
Select "Price" to map the Price field on overrides to the Price field on quote items and ticket items.
Filter Clause
Enter the following formula in Filter Clause:
FX5__CustomerAccount__c==$FX5__CustomerAccount__c && FX5__Catalog_Item__c==$FX5__Catalog_Item__c
Limit
1
Sort Clause
WellDepth__c
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.
-
Create three overrides and enter the values for the fields shown:
MinDepth MaxDepth Price Action Override1
50
500
100
Click Save & New
Override2
500
599
200
Click Save & New
Override3
600
699
300
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
You can add a cost override. This example shows adding cost overrides based on a location.
Example 1: Adding 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:
Field Entry Action Name
Enter
Cost Override by Office
Applies to SObject
Add "Ticket" and "Quote" to Chosen
Override Fields
Enter
FX5__Cost__c
This entry maps the Cost field on overrides to the Cost field on quote items and ticket items. Override Type
Select Cost
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. Limit
Enter "1"
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:
Field Entry Action Applies to SObject
Add "Ticket" and "Quote" to Chosen
Office
Select an office.
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. Override Type
Select "Cost".
Cost
Enter the cost for the office
Click Save & New.
-
Select IsActive.
-
(Optional) Set the date range in which to apply the override
-
Repeat these steps 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 these steps for other price book items as needed.
-
Price & Cost Overrides
Example 1: Adding 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:
Field Entry Name
Enter "Price & Cost Overrides by Treatment Facility"
Applies to SObject
Add "Ticket" and "Quote" to Chosen
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. Override Type
Select "Price"
Filter Clause
Enter the following:
(Treatment_Facility__c==$Treatment_Facility__c) && (FX5__Catalog_Item__c==null (pipe) (pipe) FX5__Catalog_Item__c==$FX5__Catalog_Item__c)
Replace (pipe) with the pipe character. 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.
Limit
Enter "1"
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:
Field Entry Action Applies to SObject
Add "Ticket" and "Quote" to Chosen.
Treatment Facility
select a treatment facility.
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. Override Type
Select "Price".
Price
enter the price to charge for using the treatment facility
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 the above steps 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 the above steps for other price book items as needed.
-