how can i get a correct and complete list of "stat...
# suitescript
k
how can i get a correct and complete list of "statusref" values for sales order transaction search? e.g. to know what to expect in search results, or to filter by, in code?
c
There are others, but yes, this is the right answer.
k
I was dissatisfied with "read a blog post that may or may not be out of date", and ran this down as close to the source of truth as possible. From what I can tell, these values are documented in the schema browser under the enum tab, which it's difficult to find your way to directly: https://www.netsuite.com/help/helpcenter/en_US/srbrowser/Browser2023_2/schema/enum/salesorderorderstatus.html?mode=package They just assign the letters in order of occurrence. I created a code generation step that lets me just copy the values documented at the above link and creates a full pseudo-enum in typescript with the results
this approach should be generalizable to other contexts too 🙂
i of course left the link above as a comment in my code so i can find it again 😅