Trying to cancel a return authorization like rec.submitFields({ type: 'returnauthorization', id: XXXX, values: {'orderstatus': 'C' } }) and receiving an "Invalid orderstatus reference key C." error. Cancelling using native cancel button works fine and orderstatus then switches to 'C'. Any idea what I might be doing wrong?
b
battk
08/07/2020, 1:59 PM
in general suitescript mimics the abilities of the ui
battk
08/07/2020, 2:00 PM
you cant change the order status of a return authorization by editing the return authorization and setting the orderstatus field
battk
08/07/2020, 2:01 PM
its unlikely that you will be able to do it via suitescript
s
SimonC
08/07/2020, 2:06 PM
thanks for your reply. you could change it to other status codes via the apis so i assumed cancelling would work too.
b
battk
08/07/2020, 2:07 PM
clicking buttons in the ui is equivalent to the N/action module, which does not have support for the cancel button on a return authorization