Additional approvers script

chrisdamico
Kilo Explorer

I have a variable on the catalog form; Business Unit CFO Approver (value is cfo_approver).   It's a reference to a table that has a list of the CFO's.  

In my workflow, I want to include the CFO as an approver.   In a Approval - User activity, I used the additional approvers script and added:

answer = current.variables.cfo_approver;

This is not working.   Please help.

13 REPLIES 13

Hi Chris,



If I have understand your issue correctly, then the variable 'cfo_approver' is referring to another table ('u_cfo_approver'), rather than referring to 'sys_user' table. Could you please provide a screen shot of any record from that 'u_cfo_approver' table for better understanding?


Correct.   The cfo_approver variable is a reference to the u_cfo_approver table.



I figured it out.   Had to add u_user.



answer.push(current.variables.cfo_approver.u_user);



Thanks for your help.


Hi Chris,



Great! That means I have assumed correctly.


As the variable is referring to another table instead of User table, the approval was bypassing auto-approving the record. In this case, you had to point to the exact field, of the table ('u_cfo_approver'), which refers the User ('sys_user') table. And the field is User (u_user).



I hope this helps.Please mark correct/helpful based on impact


Hi chrisdamico,



If I have answered your question, please mark my response as correct so that others with the same question in the future can find it quickly and that it gets removed from the Unanswered list.


If you are viewing this from the community inbox you will not see the correct answer button.   If so, please review How to Mark Answers Correct From Inbox View