How to Set Widget Visibility... Service Portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-13-2016 12:12 AM
1. I have a requirement to have a particular widget for a special category of the Service Catalogs.
Please can you help me out in setting the visibility of particular widget over "sc_cat_item" page for a special category of the Service Catalogs.
2. Also, I want to hide the Submit Button on the "SC Catalog Item" widget for particular service Catalog.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-16-2017 06:28 AM
Is there a way where we could have it use User Criteria? This way if we set up criteria on catalog items, we can use the same logic on the widget itself.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-16-2017 08:01 AM
User Criteria for Service Portal was released in Jakarta (see docs portal).
For the above two questions: first of all sorry for the late reply. Regarding hiding an HTML element based on a group membership, you can basically use the GlideSystem isMemberOf() function. If that returns true, you know that the user is member of the specific group. On the server, define a visibility variable in the data object to make the content available to the view (HTML) - e.g. "data.isMemberOfGroup". Then in your HTML, leverage for instance an ng-if to check for the value, e.g.: "<div ng-if="c.data.isMemberOfGroup"> your content goes here </div>".