Gm everyone. Understanding overlapping of: Workflow, User Event Triggers and Approval Processes in NetSuite is crucial for effective design. We've found this to be a common point of confusion during design reviews. Hopefully, below notes are of help to those working in NS design/customization.
1) Workflows and User Event Scripts Are Separate: Workflows do not trigger user event scripts (e.g., beforeSubmit, afterSubmit) when actions like "Set Field Value" are used. User events are not triggered by field or display changes in workflows.
2) Record Save in Workflows: If a workflow saves a record (e.g., via a "Save Record" action), it will trigger user event scripts. However, simply updating a field without saving will not trigger these scripts.
3) User Event Script Triggers: User event scripts trigger when records are created, edited, saved, or deleted. To ensure a user event is triggered after a field update, the workflow must include a record save.
4) Client Script Interaction: Client scripts can respond to field changes (e.g., via the fieldChanged event), even if triggered by a workflow.
5) Approval Process Logic: Approval workflows are triggered by specific conditions, such as changes in status or other fields, like moving a record to "Pending Approval."
6) Set Field Action and Approval: The "Set Field Value" action doesn’t directly trigger approvals unless tied to status changes or conditions that initiate the approval workflow (e.g., setting "Status" to "Pending Approval").