Would anyone know why `dialog.confirm` from `N/ui/...
# suitescript
u
Would anyone know why
dialog.confirm
from
N/ui/dialog
is failing from a Client Script's
saveRecord
entry point? For context, I am trying to create a confirmation dialog when the end-user is trying to save a Price Quote record if the
email
field in the Communications subtab is left empty. For some reason, following the standard implementation of the documentation allows me to click "OK" on the dialog without anything happening. Would appreciate any and all inputs, thanks.
b
fair chance you arent taking iinto account dialog.confirm is asychronous
the saveRecord entry point requires a synchronous return of true or false, meaning that by the time a user clicks that button, the saveRecord is already done running and you have already returned whether to save the record or not