How to Restrict Requestors from Viewing Ineligible HR Services on the Backend Case Creation Page

ChunjiJ
Tera Contributor
HR Criteria configured on HR Services only validate against the Subject Person and cannot directly restrict Requestors from searching for ineligible HR Services in the backend (Agent Workspace / Case Creation Page).
 
I want to ensure that ineligible Requestors are completely unable to see or search for the corresponding HR Services when creating HR Cases in the backend. Could you advise on how to configure this?
2 REPLIES 2

Naveen20
ServiceNow Employee

Before Query Business Rule on sn_hr_core_service — this is the best option because it filters ineligible services before they appear in any search, reference picker, or list in the backend, without affecting the Subject Person evaluation on the portal side.

 

  1. Go to System Definition → Business Rules → New
  2. Table: sn_hr_core_service
  3. When: Before, Query checked
  4. Condition: Runs in backend context only
  5. Script: Use sn_hr_core.HRCriteriaEvaluator to check criteria against gs.getUserID(), then append an encoded query to exclude services the current user doesn't qualify for.

This keeps OOB HR Criteria behavior intact for the portal/Subject Person flow while adding requestor-level filtering in Agent Workspace and backend case creation.

Ankur Bawiskar
Tera Patron

@ChunjiJ 

see this link on how to restrict

How to restrict “Opened for” users based on assignment group type in HR Agent Workspace? 

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

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