Extend Default Context Definition for Work Order Estimation
You can extend the Out-Of-The-Box (OOTB) context to create a custom context definition with additional attributes, without modifying existing ones. Similarly, you can extend the mapping to include additional mappings, without changing the existing ones.
Required Editions
| Available in: Lightning Experience |
| Available in: Automotive Cloud, Communications Cloud, Energy and Utilities Cloud, Manufacturing Cloud, Service Cloud, and Media Cloud. View edition availability. |
| User Permissions Needed | |
|---|---|
| To set up Salesforce Pricing | Salesforce Pricing admin AND Salesforce Pricing Manager AND Salesforce Pricing Design Time User |
- From Setup, in the Quick Find box, enter Context Service, and then select Context Definitions.
-
On the Standard Definitions tab, find WorkEstimationCoveragesContext, click the dropdown
menu, and choose Extend.
The Context Definition page appears.
-
Enter context definition details.
- Enter a name and description for the custom context.
-
Click Next.
The Create Structure page appears.
- New nodes aren't supported. Click Next.
-
Add attributes.
- Add new attributes at the correct node level. For each new attribute, select the appropriate Type (Input, Output, or InputOutput) and DataType.
- If applicable, fill in the Referred Object field (this is auto-populated based on the hierarchy).
- Click Next.
-
Create attribute tags.
-
Create unique attribute or context tags for the new attributes.
These tags must be unique within the entire context. These tags are used to identify attributes across levels within the context and also in the Pricing Procedure Definition.
-
Save your changes.
The new context definition is created and listed on the Custom Definitions tab with its status set to Inactive.
-
Create unique attribute or context tags for the new attributes.
- On the Custom Definitions tab, open the custom definition you created.
-
Go to the Map Data tab.
By default, an extension of the OOTB context mapping (IFSQuoteLineItemEntityMapping) is listed.
-
From the dropdown menu for IFSQuoteLineItemEntityMapping, select
Edit.
The Edit Mapping page appears.
-
Select the Mark as Default check box and then click
Map.
The Context Mapping’s builder page opens in a new tab.
-
Link the new or existing unmapped attributes on the Structure tile to the corresponding
entity fields on the Connect Objects tile. First, select the attribute, then select the entity
field.
You can map the fields only if the parent node level maps to the corresponding entity. These mappings are provided by default as this mapping extends the OOTB context mapping.
-
Map attributes to entity fields within foreign key references in the parent entity.
-
Click the Add icon next to the foreign key field.
For example, Product2Id.
- Select an appropriate field from the list.
- Make sure the entity field path is correct, doesn’t contain repeated characters, and then map the desired attribute to this field.
- Save your changes.
-
Click the Add icon next to the foreign key field.
- On the Context Definitions page, go to the Custom Definitions tab.
-
From the dropdown menu for the context definition you created, select
Activate.
The status of the context definition changes to Active.
Did this article solve your issue?
Let us know so we can improve!

