I am writing a RESTlet that creates Cash Sales in Dynamic mode. Some of the items we have will need their Inventory Details set, but others, namely Inventory Items, do not. Once they're added to the order, their bin numbers are automatically set.
In SuiteScript 2.1 how can I determine if an item's Inventory Detail needs set or not. If it makes a difference or not, this subrecord is on the line of a sublist that was selected with selectNewLine.
I have already tried getting the Inventory Detail record.Field and seeing if its isMandatory is true, but this doesn't seem to change regardless of whether it needs set or not.
I have also tried checking if the subrecord already exists with hasSublistSubrecord, but this also seems to not change regardless of whether it needs set or not.