Restrict user to resolve the P1/P2 incidents. and only Group-A should have access to resolve them

bankuru bhargav
Tera Contributor

Hi All,

I'm trying to restrict, the users to resolve the  P1/P2 incidents. and only Group-A have access to resolve the P1/P2 Incident. how can we achieve 

12 REPLIES 12

Hi @bankuru bhargav 

 

AGLearnNGrow_0-1710326922749.png

 

AGLearnNGrow_1-1710326944241.png

 

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Condtion: (current.incident_state != 7 && current.incident_state != 6) && (gs.hasRole("itil") || gs.hasRole("itil_admin"))

 

Code:

function resolveIncident(){

 g_form.setValue('incident_state', 6);

   g_form.setValue('state', 6);

gsftSubmit(null, g_form.getFormElement(), 'u_resolve_incident'); 

}

if (typeof window == 'undefined')

   serverResolve();

 

function serverResolve(){

   current.incident_state = 6;

   current.update();

}

Currently we are using this above script  if we add the mentioned  condition applicable for only this group only 

(current.getRecordClassName() == 'incident' || current.getRecordClassName() == 'problem') && gs.getUser().isMemberOf('SN_IT Managers') may i know how it work 

bankurubhargav_0-1710329996375.png

I have created a businees rule with below condtion when this condtions meat only Group-A should have access to resolve them. in this case wat condtion i should add in the scrpit to achive it 

bankurubhargav_1-1710330112152.png

 

Hi @bankuru bhargav 

 

I am not sure, why you write script, you can add just a condition as said earlier. 

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

if we use that condition, how the system will now p1/p2 incidents are going to be resolved by particular group called Group-A

(current.getRecordClassName() == 'incident' || current.getRecordClassName() == 'problem') && gs.getUser().isMemberOf('GROUP-A') may i know how it work 

example if i raise a incident with P4 then it should be resolve by anyone