I'm using a beforeSubmit UE script on a PO transac...
# suitescript
w
I'm using a beforeSubmit UE script on a PO transaction, which has a client script attached that updates a field. The client script updates the field, but when the record is saved, scriptContext.newRecord.getValue('custbody_field_updated_by_client_script') returns a zero length string. Is this a known issue?
c
Is the field configured to store value? Do you know that the field value is updated because you can see it set in the UI? When you load the PO again, is the value present or is the field blank?
w
@Clay Roper Yes, the field has the value stored. The field is updated in the UI before save. The field is populated on PO reload. It's a long text field meant to hold a JSON string.
Turns out I had two script records pointing at the same script file in the file cabinet. Not sure if that was an SDF error. One script record had a custom internal id that I gave it, and the other had a system generated internal id (scriptrecord1038). I didn't think you could do that.