New tab customization in agent workspace (chrome_tab)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2025 04:12 AM
Hi All,
I have two different set of audience for service operation workspace if audience abc logged in to the instance he should see only new interaction tab and if xyz audience logs in then they should see only new change and new incident not new interaction.
I have wrote this in chrome tab value
{
"contextual": [
"record",
"kb_view"
],
"newTabMenu": [
{
"label": {
"translatable": true,
"message": "New Incident"
},
"routeInfo": {
"route": "record",
"fields": {
"table": "incident",
"sysId": "-1"
},
"multiInstField": "sysId"
},
"condition": {
"script": "var groups = ['one Help desk', 'one help desk - quality check', 'one help desk - specialist', 'one help desk - sap', 'one help desk - teamleads']; for (var i = 0; i < groups.length; i++) { if (GlideUser.isMemberOf(groups[i])) return false; } return true;"
}
},
{
"label": {
"translatable": true,
"message": "New Change Request"
},
"routeInfo": {
"route": "create-change-request-page",
"fields": {},
"multiInstField": ""
},
"condition": {
"script": "var groups = ['one Help desk', 'one help desk - quality check', 'one help desk - specialist', 'one help desk - sap', 'one help desk - teamleads']; for (var i = 0; i < groups.length; i++) { if (GlideUser.isMemberOf(groups[i])) return false; } return true;"
}
},
{
"label": {
"translatable": true,
"message": "New Interaction"
},
"routeInfo": {
"route": "record",
"fields": {
"table": "interaction",
"sysId": "-1"
},
"multiInstField": "sysId"
},
"condition": {
"script": "var groups = ['one Help desk', 'one help desk - quality check', 'one help desk - specialist', 'one help desk - sap', 'one help desk - teamleads']; for (var i = 0; i < groups.length; i++) { if (GlideUser.isMemberOf(groups[i])) return true; } return false;"
}
}
],
"maxMainTabLimit": 10,
"maxTotalSubTabLimit": 30
}
in above script when I used applies to :["audience sys id"] it didn't work so I tried with group.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2025 04:32 AM
Does script work there?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2025 04:37 AM
you can either show/hide them completely and not based on condition
Workaround: you can use table level CREATE ACL and block it by using advanced script in the ACL of interaction table itself and if user doesn't satisfy the role then it's gone.
Hide New Interaction Button on Workspace based on Conditions - Service Operations Workspace
How to hide 'New Interaction'?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2025 05:05 AM - edited 05-02-2025 05:05 AM
Completely hide using acl and in advanced condition I can mention if logged in user not part of particular group then they can see new change and new incident tab?
can you please let me know how to configure the acl for the same?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-05-2025 06:08 AM
not based on role, based on group or audience I want the tab button to hide/ show. can you please assist?