Hi All, I'm attempting to avoid closing a PO, the ...
# suitescript
g
Hi All, I'm attempting to avoid closing a PO, the idea is to validate if there is at least one item line pending billing when the close button is hit; if so, the order should not be closed. I'm using a user event script, but the close action doesn't seem to go into the script. Does anyone know if it's possible to catch the close event of the PO in a script when the close button is hit?
e
So, we introduced our own statuses (one being Closed). Then, in the beforeload, if the PO status is closed, but the custom status is NOT closed, we perform a function, then set the custom status to Closed.
Then, redirect back to itself
g
Thanks @battk and @ExtendApps Inc. I will give another approach to the solution.