Hello, I have a User Event script executed on afte...
# suitescript
k
Hello, I have a User Event script executed on afterSubmit, which is deployed against Revenue Arrangement record creation. The script is supposed to get the commission value from a custom field in the associated Sales Order and update this value in Rev Arrangement's CONTRACT ACQUISITION COST AMOUNT (BASE CURRENCY) field on
scriptContext.UserEventType.CREATE
. However, I keep on getting this error:
Copy code
"name":"HEADER_CONTRACT_COST_DOES_NOT_EQUAL_SUM_OF_LINE_CONTRACT_COST","message":"The Contract Acquisition Cost Amount does not equal the sum of the Allocated Contract Acquisition Cost Amount values on the revenue elements."
The same script works if I change the script to ``scriptContext.UserEventType.EDIT` . Has anyone experienced this issue?