Will nlapiSubmitField trigger user event scripts?
# suitescript
d
Will nlapiSubmitField trigger user event scripts?
b
They do normally fire the beforeSumit and afterSubmit, but not beforeLoad. Type is "xedit"
nlapiGetFieldValue returns NULL for fields not submitted, (so need to be looked-up if logic depends on values)
d
My question was just about nlapiSubmitField
Thanks
b
If the field is INLINE or HIDDEN I think nlapiSubmitField uses nlapiLoadRecord / nlapiSetFieldValue / nlapiSubmitRecord - so this may cause a "normal" user event chain
d
Interesting
Since nlapiSubmitField is so quick, it feels like it is skipping the UE chain.
b
My reasoning for mentioning the "nlapiGetFieldValue" is that this can return NULL when used in User Events that are trigger via nlapiSubmitField - caught us out a few times before 🙂 The user event receives a "trimmed down" version of the record so seems much more efficient - a bit like when using inline-editing on search views
b
there is a very long topic on inline editing and suitescript
its easy to get wrong