catalog item access to specific user

RajeshwariHP
Tera Contributor

Hi 

We have a requirement to give the temporary access to one of the catalog item for specific user but user location is already added in the Not Available For condition using user criteria. Any other options to achieve this.

 

Thank you

Rajeshwari H P

5 REPLIES 5

Akansha Gupta
Mega Sage

hi @RajeshwariHP  - The Not Available For settings override Available For settings. A user on the Not Available For list for an item cannot access that item, even if that user is also on the Available For list for that item.

Please use script as per your requirement in not available for rather so it not having chance to override values.

AkanshaGupta_0-1738659254023.png

 

"If you found my answer helpful, please mark it as the "accepted solution". It helps others find the solution more easily and supports the community!"

Runjay Patel
Giga Sage

Hi @RajeshwariHP ,

 

Option1: you can amend the existing user criteria like user is not xyz.

 

Option2: You can script like below in your user criteria which is present in not available along with existing condition.

var userSysId = gs.getUserID();
if (userSysId == 'USER_SYS_ID') { // Replace with the user's Sys ID
    answer = true; // Allow access
} else {
    answer = false; // Deny access
}

 

Option 3: Temporarily Remove the User from the Restricted Location

 

 

-------------------------------------------------------------------------

If you found my response helpful, please consider selecting "Accept as Solution" and marking it as "Helpful." This not only supports me but also benefits the community.


Regards
Runjay Patel - ServiceNow Solution Architect
YouTube: https://www.youtube.com/@RunjayP
LinkedIn: https://www.linkedin.com/in/runjay

-------------------------------------------------------------------------

 

Ankur Bawiskar
Tera Patron
Tera Patron

@RajeshwariHP 

workaround here

1) remove the Not available for sometime

2) then add Available available for user criteria (create a fresh one for that user)

3) once request is submitted remove from Available for and add in Not available for

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@RajeshwariHP 

Hope you are doing good.

Did my reply answer your question?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader