has anyone already created approval logic by scrip...
# suitescript
m
has anyone already created approval logic by script and not by workflow? In the idea I would like the user to be able, from a custom record or other, to define different approvers according to a logic depending on analytics, geographical area and other field in order to give them control more easily than coming into a workflow or several workflows to add special criteria..
e
Interesting... How would you define the current step in a multi-step approval route, when using a script? A custom field?
m
Honestly it's an idea I had and I wanted to know if anyone had already done something similar via script. But maybe for the step , transition Étc a custom field it’s a good idea
f
Creating an approval logic via script is straightforward. Introducing a custom record into that opens a security hole.
e
In a Workflow I have some functionality very easy to implement: 1. Creating buttons and use them as go-to for the other states. 2. Complex routing and branching (above some amount threshold, set a second approval level after the first is done, etc). 3. Creating Saved Searches for transactions in specific WF states. 4. Reset and relaunch an approval process. 5. Audit teams ask me about changes form six months ago and the WF history is still there. Script logs are ephimeral. Using a script to set the
nextapprover
, then set the transaction as
approved
can be done very easy. Other things, not so sure.
1