has anybody been able to allow a client script to ...
# suitescript
a
has anybody been able to allow a client script to load a record, when that record is locked by another workflow?
l
If you just need read the record, try to use the lookupField. I'm not sure you can load a blocked record.
a
thank luiz, i came to the same conclusion but was hoping i wouldn't have to go that route. appreciate the confirmation
a
@al3xicon Can't you have the workflow only lock the record when context is UI? Exclude Client Scripts on the workflow.
a
i thought so but User Interface appears to be the context for both
let me look again
e
Isn't Client the same context? Pretty sure it is, @al3xicon as you suspected
a
i thought so but now i see a "Client" context and i'm not sure what that is, so I want to check the context setting to see if it helps - i doubt it will
but when i looked closer i saw that i am seeing a different error than the user was - even in their role - my error message has to do with permissions, not locked records, though they look similar from a glance
yeah it looks like @Aria Ghahari is correct here - when i limit the workflow lock record action to only User Interface, it does not appear to get the error when loading the record via script
@ec I think this may be a more recent thing though? I feel like in previous NS versions it was definitely the case that client scripts shared the same context as User Interface
a
Glad that works. I have been setting the context of my workflows to "UI" for more than a year now. I am not sure when this feature was added.
a
good to learn something today, even if it's something i "read" over a year ago and should have remembered!
e
cool, all.