Some PDIs are currently unavailable, and PDI actions are paused. View the latest updates here. Read More

Edit fields after incident is closed

Pedro33
Tera Contributor

Is it possible to allow a specific group to edit certain Incident fields after the Incident is closed?

I need members of one group to update a few fields after the Incident state is Closed. I already verified the user's group membership with a Script Include, but the fields remain read-only.

What is the recommended approach? Should this be handled with UI Policies, ACLs, or another method?

6 REPLIES 6

Its_Azar
Mega Sage

Hi there @Pedro33 

You can but why? once its closed its closed, and we shouldn't mend with ta closed inc. 

if absolutely needed check ootb ui policy and ack or just create one.

☑️ If this helped, please mark it as Helpful or Accept Solution so others can find the answer too.

Kind Regards,
Azar
Serivenow Rising Star
Architect@ KPMG.

Umar Akbar
Tera Contributor

@Pedro33,

 

Yes, this is possible. However, its not a best practice and should avoid on Incident records.

 

Still, if that's a hard requirement at your end, here's how you can do that:

1. Add a record-level write ACL (the "building key").

ACLs at the same level evaluate with OR, so you don't have to edit the OOB one (leave it alone - editing OOB records invites upgrade pain). Create a new incident / write ACL whose script grants access when the user is in your group, even when closed:

answer = false;
var state = current.getValue('state');
// 7 = Closed, 8 = Cancelled — verify against your state choice list
if (state == 7 || state == 8) {
    answer = new YourGroupCheck().isUserInSpecialGroup(gs.getUserID());
    // or simply: answer = gs.getUser().isMemberOf('Your Group Name');
}

Now, when closed: normal itil users fail both ACLs and stay locked; your group members pass this one and get record write access.

 

2. Scope it to the specific fields.

Step 1 opens the whole record for the group. To keep it to a few fields, the cleanest path leans on the fact that the form automatically renders any ACL-read-only field as greyed out — you don't need a client script for that. So:

  • Copy/deactivate the OOB "Make fields read-only on close" UI Policy and, in your version, remove your target fields from its read-only actions. Now those fields aren't force-disabled on the form.
  • For the group, the record-write ACL from step 1 makes them editable. For everyone else, they stay read-only because those users fail the ACL and the form greys them automatically.

 

 

If my answer has helped with your question, please mark my answer as the accepted solution and give a thumbs up.

Best regards,

Umar