Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Need help on Workflow Approvers matrix on Workflow activity

Mohammedwaseem
Tera Contributor

we have a requirement for our custom table workflow.

 

3 levels of Approvals

first level= Requestor manager

second level = General manager /CE group / SE group

third approval = Leadership Group Approval

 

For second level approval , we have following criteria

there is Cost center field with value numeric.

if cost center = 1-100 ->then approval should trigger to CE group

if cost center = 101-200 ->then approval should trigger to SE group

if cost center = unlimited -> then approval to General manager

 

written below code on Workflow activity Run script.  

var cost = current.cost_center;
if (cost >= 1 && cost <= 100) {
        var userGR1 = new GlideRecord("sys_grmember");

        userGR1.get("group", current.sys_id);

        return userGR1.getUniqueValue();
		
    }

 

 

How to add approvers based on criteria using workflow activity?

I am unable to configure second level.

 

Please help me as i am new to servicenow.

0 REPLIES 0