I want to close a Vendor Return Authorization and ...
# suitescript
n
I want to close a Vendor Return Authorization and unsuccessfully tried this snippet with Vendor Return Authorization:Closed being VendAuthH Any tips?
var resultVRA = record.submitFields({
type: record.Type.VENDOR_RETURN_AUTHORIZATION,
id: newVRAid,
values: {
'orderstatus': 'H'
}
m
Similar to the sale type transactions, you can't set this status directly. Instead, loop through each of the sublist items and set
isclosed
to
true
. After they're all closed, the overall transaction status will be closed. You won't be able to use
submitFields()
to do this, unfortunately.
👆 2
👍 1
n
thanks.