Publication Workflow Approval Scripting
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2025 09:02 AM
Hello.
I am trying to update a publication workflow activity to dynamically assign the Publication creator's manager from the sys_user table as the approver.
I have had no luck in my configurations or getting the script right, any advice would be greatly appreciated.
Script:
var creator = current.sys_created_by;
var userRec = new GlideRecord('sys_user');
userRec.addQuery('user_name', creator);
userRec.query();
if (userRec.next()) {
var manager = userRec.manager;
current.approver = manager;
}
Workflow Activity Configuration:
Labels:
- Labels:
-
scripting
0 REPLIES 0