I have a user event attached to Customer changes. ...
# suitescript
b
I have a user event attached to Customer changes. The Event Type on the deployment is blank, so I'm expecting to get all event types (including XEDIT). If I edit a Customer, modify one of the Customer's addresses, and save the Customer, my script is executed. If I go to a Sales Order for that customer, to the address tab, and select the Edit button next to Ship To or Bill To, I can edit that same address and save the change but my script is not executed. Can anyone tell me what type of entity or event I need to attach to so I can catch the address change from the sales order page?
b
a user event script cannot be deployed to the address subrecord, it wont capture events from an address
client script can be deployed addresses, though great care should be done while doing so
it has special behavior in server scripts
b
In the past we've worked around this by retrieving all addresses for an order's customer whenever we handle an order sync, but that seemed inefficient. We were hoping for a way to trigger on the one address that was changed. Sounds like we're out of luck there?
b
id go for syncing all addresses
you can be better by using N/query to limit to recently changed addresses since there is a last modified date column you can query against