New thread: Purchase Order Approval Workflow. Currently, the workflow locks the PO when approved. This happens immediately because the user is an Administrator and the approval goes through immediately during creation. I have code running in the background upon Create to load the record, get some data, and then setting a few fields on the PO. The Lock prevents the programmatic loading of the record. I removed the Lock Record action from the workflow but somehow, what I need to do is the following:
Create PO - Upon save, trigger PO Approval Workflow > Code executes, sets a field value > retrigger a state in the workflow to check conditions > if conditions met, Lock Record.