As a NetSuite consultant, I constantly find myself using NetSuite Workflow to automate business process in lieu of having a developer write code. In this use case, we’ll help you use NetSuite Workflow to create an After Field Edit triggered action to calculate a commission value for a sales rep based on the sales rep’s participation percentage in a deal.
A field on an order form tells us the value of the deal, but it’s up to the user entering the order to set the percentage participation of the rep in this deal. Rather than manually doing the math, the user would like the value due to the sales rep automatically calculated upon entering the participation percentage.
In this example:
- The order value is $250,000.00
- The sales rep’s participation was 20% of the total order value
- The user would like the “Rep Commission” field to display $50,000.00 ($250,000 * 20%) automatically
A workflow using an ‘After Field Edit’ trigger could accomplish this by running the calculations after edit of the Order Value Field or the Rep Percentage field.
- The ‘After Field Edit’ trigger on Workflow actions allows fields to be updated automatically, in real-time.
- Setting this trigger type allows the user to update a field value based on whether one or more other fields on that form are updated by the user.
- When setting up a new workflow action, choose trigger on “After Field Edit.”
- Choosing the ‘After Field Edit’ trigger will require the user to select one or more ‘Triggering Client Fields.’ These are the fields which must be edited in order to trigger the workflow to update the field in question, not the fields whose values will be changed by this workflow state.
- If this field should only be updated under certain conditions, you can specify those conditions in the ‘Condition’ area. If this workflow state is calculating a value based on one or more other fields, it is recommended to set a condition that these fields contain data. If you neglect to do this, you may receive errors from NetSuite relating to null values.
- In the ‘Parameters’ area, select the field you want this workflow action to update. You can set it to:
- A static value (the value will always be set to that value on update of the triggering client field)
- A value from another field on the record
- A custom formula to calculate a new value – this is what we’ll be using in our example
- If your workflow contains more than one action with the ‘After Field Edit’ trigger, be mindful of dependencies between them. If one action cannot properly function without a field value being set by another action, put them in the right order by clicking and dragging the workflow actions in the workflow editor. Save your changes when finished.
- Ensure the workflow is in a mode of ‘Testing’ or ‘Released’ to view the workflow in action on your forms.
Need more help? MIBAR offers expert NetSuite support. Contact us today to learn more.
Additional NetSuite Resources
Creating Filtered Dropdown Lists in a Custom Field in NetSuite
6 Tips for NetSuite Advanced PDF Templates
Dynamically Print Items on a Netsuite Sales Order Using Advanced PDF Templates