Show inactive users on a reference variable
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-03-2022 09:24 AM
I have one specific service that I want users to be able to submit a case for an inactive user. I want an inactive users to show up on the subject person reference variable. Currently, only admins can see inactive users on a reference variable. I believe this is because of the business rule, "user query". Is there any way I could edit this business rule to work for everything except one specific service?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-03-2022 09:37 AM
Yes, of course you can edit that Business Rule, or even deactivate it. But you cannot disable it only when the user is viewing a specific catalog item field. Users can either see inactive users, or they can't. To the best of my knowledge, there is no concept of "Users can see this record, but only through this specific reference field". That isn't how access or permissions work (and rightfully so).
You'll have to decide (or rather, your company will have to decide) if they want user records to be visible when inactive or not.
One option would be to make a more granular rule - such as by allowing an additional role (aside from admins) to see those users, in which case the BR would not fire. You can adjust that in the Condition field of the BR form.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-27-2022 06:19 AM
I ended up creating a new "employee_relations" security role, assigning it to the users I want to see inactive users, and then editing the business rule. How I have the BR now is working, but I'm a little confused because I feel like this script is saying if the user does NOT have "employee_relations" they should be able to see inactive users.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-31-2023 11:47 PM
I added a condition for a few reference fields I specifically wanted inactive users to be excluded.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-03-2022 01:34 PM - edited ‎10-03-2022 01:54 PM
Are these cases created through a portal or native UI?
If it's on the portal, on the reference variable, add this advanced qualifier
And update the User Query business rule script to this
var query = current.getEncodedQuery();
if (gs.getSession().isInteractive() && !query.includes('activeANYTHING')) {
current.addActiveQuery();
}
Note this is an unsupported customization.