Hi so this error only shows up if the item that we...
# suitescript
j
Hi so this error only shows up if the item that we are changing from are using BINs. If we disable BINS on the original invoice, the script works fine. Can you tell me what is this error? It basically happens when saving an invoice. “Message: An unexpected SuiteScript error has occurred, Stack: Error at RecordInvoker.save (suitescript/resources/javascript/record/serverRecordService.js37113) at NetSuiteObject.thenableFunction() (suitescript/resources/javascript/record/proxy.js11524) at Object.afterSubmit (/SuiteScripts/CustomScripts/UE_changeItemLocations.js16729)”
a
the error text isn't that specific in this case. the only useful information in there is
Error at RecordInvoker.save
and
UE_changeItemLocations.js:167:29
all that's telling me is that there's a record save event that is failing and it is triggered from the changeItemLocations script at line 167. The problem though is that the 167 line probably just says itemRec.save(); so the actual issue is potentially before that and something is wrong with itemRec... or the save event is triggering some other scripts/WFs and THEY are actually what's causing the issue. There's really no way of knowing without getting in there and reviewing things