- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2017 12:47 AM
Hello,
There is an OOTB business rule for sys_user table called user query, which has a condition: gs.getSession().isInteractive() && !gs.hasRole("admin")
It blocks access to deactivated sys_user records for non admins.
However when I add the additional condition for itil users: gs.getSession().isInteractive() && !gs.hasRole("admin")|| !gs.hasRole("itil") it still doesnt work.
Could someone please help me with this?
Many thanks
Kind regards
RG
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2017 12:53 AM
I think you have to use && instead of ||
like
gs.getSession().isInteractive() && !gs.hasRole("admin") && !gs.hasRole("itil")
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2017 12:52 AM
Hi Rokas,
Try putting the two role conditions in their own parentheses:
gs.getSession().isInteractive() && (!gs.hasRole("admin")|| !gs.hasRole("itil"))
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2017 01:51 AM
Thanks Dave!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2017 12:53 AM
I think you have to use && instead of ||
like
gs.getSession().isInteractive() && !gs.hasRole("admin") && !gs.hasRole("itil")
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2017 01:50 AM
Thanks Mihir,youre absolutely right:)
I cant believe I missed it