Quote Contexts
As a reminder, calculated quote data can depend on the quote context from the CRM, but must never depend on a particular user context.
This is because the next user accessing a quote will naturally re-populate the quote context from the CRM, and so the data cannot be altered according to the last user connected, bearing in mind that several users may see the quote in competition.
The same applies to the management of user rights, which may be based on fields, but which, in this case, cannot be conditioned by data from a particular user context, as otherwise one user could take advantage of the acces rights of another user.
However, in the case of user rights, session variables offer the very possibility of conditioning user rights to a particular user context, as these variables are specific to the user session.
In conclusion, it is imperative never to store data specific to a particular user in a field, although such data can be used to manage access rights via session variables.
The quote context is used to share data between an external system and Performance Quoting. The context is sent when the quote is created/opened in an external system such as a CRM. The context contains information needed to open a quote as well as data coming from the CRM and that can be leveraged in the quote.
From the action bar you can add a context, duplicate, and delete. The list of contexts are in the left panel. Select a context (click on it) to configure it in the window on the right. You can add session variables and field mapping. Use the buttons on the top of the right window to switch between these options.
Session Variables
For each context, you can define session variables. Session variables are used to store information related to the user session such as the user profile from the CRM.
To create a session variable, click Add Session Variable. Define the following:
- Name
- Type
- Key
- JSON Path (Optional)
Follow the creation procedure above to define a new session variable
Identify, in the CRM context, the path to the element you want to retrieve
Set the corresponding JSON Path in the ad-hoc column of the session variable definition:
- Save
Do not use Field Mapping below to address this scenario as Session Variables are the only means to do it.
Get Field Mapping
As explained for data sources, you can define one or more field mappings to retrieve data for the context. As context data sources only retrieve information from an external system, there is no input mapping, only output mapping.
Click Add Map to add a map. A map is defined by a Name and Refresh policy. To add output mapping, click Add Output Mapping.
Define the output key and a field. Click Add to save.
