How to customize OOB copy Incident UI Action

Community Alums
Not applicable

Hi all,

When we click on OOB Copy incident UI action it will create new incident by copying some field value from old incident form. In our case the assignment group field value also got copied from old incident to new incident from, but the assignment group is not active now and there is no member in that group, 

Is there any way to restrict the inactive assignment group getting copy into new incident from old incident while clicking on COPY Incident UI action.

 

Is there any possible ways to do that?

 

we are using OOB UI action we have not yet customized that.

 

Anyone can help me on this,

Thanks.

6 REPLIES 6

jaheerhattiwale
Mega Sage
Mega Sage

@Community Alums You can create the exact duplicate of the ui action and keep order less than the OOTB one. Then UI action you created will override the OOTB.

Your ui action will be visible on the form.

Do required changes in your UI action.

 

Please mark as correct answer if this solves your issue.

Please mark the answer as correct or helpful based on impact
ServiceNow Community Rising Star, Class of 2023

Sebas Di Loreto
Kilo Sage
Kilo Sage

@Community Alums 

You control this feature through the "incident properties"

 

SebastianDL_0-1671555890093.png

 

 

SebastianDL_1-1671555919659.png

 


If I helped you with your case, please click the Thumb Icon and mark as Correct.


@Community Alums 

I think you should opt to leave the out of the box UI action intact and, as a good measure, have a business rule that checks if the assignment_group is active (or empty, or no itil type, etc.) BEFORE saving the record. If not, then abort the saving.


If I helped you with your case, please click the Thumb Icon and mark as Correct.


Community Alums
Not applicable

Hi @Sebas Di Loreto 

 

I have tried the below on Submit client script but it is not working for ITIL users

function onSubmit() {
var a = g_form.getReference('assignment_group');

var cal = g_form.getValue('caller_id')
    if(g_user.hasRole("itil") || g_user.hasRole("sn_incident_write") || cal == g_user.getUserID ){
      if (a.active == 'false'){
         g_form.showFieldMsg('assignment_group', 'Invalid assignment group', 'error');
        return false;
        }
    }

Can you please help me on this or provide Business Rule