Restrict visibility announcement on portal to specific groups.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
Hi,
I have a requirement to restrict the visibility of an announcement tile on the portal so that only members of specific groups can see it.
What I have done so far:
- Unchecked the Public option on the announcement
- Added User Criteria under Can View
- In the User Criteria, I specified the required groups and saved it
Issue:
Even though I am not a member of those groups, I am still able to see the announcement tile on the portal.
Additional details:
- The announcement is being fetched and displayed using a custom widget
- I suspect the User Criteria may not be getting evaluated properly at the widget level
Questions:
Why am I still able to see the announcement even though I don’t meet the User Criteria?
Does User Criteria automatically get enforced when announcements are fetched via a custom widget?
Do we need to explicitly evaluate User Criteria in the widget server script to restrict visibility?
If yes, what is the recommended way to evaluate User Criteria or group membership in the widget?
I am sharing the widget code below for reference.
Any guidance or best practices on implementing this requirement would be really helpful.
Thank you!
CODE:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
53m ago
refer below links for help
Trying to edit User Criteria for SP Announcements, pages, and widgets.
How can we display announcement based on user location
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader