How to show/hide a widget based on some conditions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-18-2020 07:08 AM
I had a widget with a single button it needs to visible only when an incident is in the resolved state. if it is in other states then the widget need to hide
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-18-2020 07:12 AM
where are you using the widget and how?
you can have user criteria for widget
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-18-2020 07:35 AM
In Pages[sp_page], for a particular page there are 4 widgets already...
so I have added a new widget, widget consists of a button... It needs to visible only when the incident state is resolved
I think user criteria will not be worked here...because I need to set a condition based on an incident state..i.e., when incident state is resolved the widget need to show otherwise hide
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-18-2020 08:09 AM
Hi,
that's correct.
then somehow in the widget script you need to access the incident record and based on state show/hide the button
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader