This Extension Point allows a script to allows custom filters by a Groovy extension point to show a sales user only the relevant personnel, e.g., within a certain functional and regional scope.
Initial Setup
Upload the script file to the Groovy Script with the name “Quote Routing Recipients”. Please refer to Groovy Service Introduction - Uploading a New Groovy Script for more details of how to do this.
Additional Binding Variables
The following binding variable(s) are made available for this extension point, in addition to the common binding variables listed in Groovy Service Introduction - Common Binding Variables.
Variable Name |
Class |
Description |
---|---|---|
routingUsers |
Collection<BusinessObject> |
The list of users that could be routed to by default. The script may add and/or remove items in this list to modify the users that can be routed to. |
routingSalesTeams |
Collection<BusinessObject> |
The list of sales teams that could be routed to by default. The script may add and/or remove items in this list to modify the sales temas that can be routed to. |
salesItemsTree |
SalesItemsTree |
Represents the Quote, it contains the functions that can be used to query the quote and its line items data as well as to modify them. |
Expected Output
No output is expected. However, any changes to the binding variables routingUsers and routingSalesTeams will be used to process which users and sales teams should be displayed in the Route Quote pop-up window.
Script Execution
The script that has been uploaded for this extension point will be executed automatically when the user clicks on the Actions > Route button to display the Route Quote pop-up window, if the script is uploaded. Only the users and sales teams as allowed by the script will be displayed here. If the groovy script is not uploaded, standard implementation is executed.
A common use case is to limit the users that can be routed to based on the Org Unit hierarchy. A helper function is also provided to make this easier: groovyCtxUtil.getOrgUnitHierarchy(). Please refer to the Javadoc for more details.