Specific knowledge base which should be visible only to end users(users with no roles) in portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā06-10-2025 01:53 PM
Hi,
I have created some knowledge bases that needs to visible only to users with no roles
I have defined user criteria But its not working specifically I have impersonated Itil and admin
In Cannot read user criteria i have gave this code
(function() {
var roleGr = new GlideRecord('sys_user_has_role');
roleGr.addQuery('user', user_id);
roleGr.setLimit(1);
roleGr.query();
return roleGr.hasNext(); // true if user has any roles
})();
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā06-10-2025 07:03 PM
Hi @Bruce lee ,
Can you explain why someone with no roles should see these Knowledge base and with roles , they won't? as in real world, if you someone who has no roles can see the knowledge base if you make it public. However, this would be visible for anyone in the platform.
Sandeep Dutta
Please mark the answer correct & Helpful, if i could help you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā06-10-2025 11:08 PM
That's the client requirement for end users alone specfic Knowledge base needs to be viisble so ur telling technically its not posible right