- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-29-2020 10:34 PM
Hi,
Is it possible to hide the "Manage Attachments" link and the attachments based on users/ groups on the incident form.
Regards,
Hemanth
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-30-2020 03:46 AM
Hi Hemanth,
The manage attachments is to be shown or hidden to particular assignment group on incident form or always it should check if logged in user is member of particular group
Do ensure you add your logic but below is how you can do using DOM
Note: It is not recommended to use DOM
Ensure You use below
1) Isolate Script field to false
2) This field is not on form but from list you can make it false
Sample script below
1) To hide entire row of Manage Attachments and the attachments
function onLoad(){
document.getElementById('header_attachment').style.display = 'none';
}
2) To hide only the Manager Attachments link use this
function onLoad(){
document.getElementById('header_attachment_list_label').style.display = 'none';
}
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-30-2020 03:46 AM
Hi Hemanth,
The manage attachments is to be shown or hidden to particular assignment group on incident form or always it should check if logged in user is member of particular group
Do ensure you add your logic but below is how you can do using DOM
Note: It is not recommended to use DOM
Ensure You use below
1) Isolate Script field to false
2) This field is not on form but from list you can make it false
Sample script below
1) To hide entire row of Manage Attachments and the attachments
function onLoad(){
document.getElementById('header_attachment').style.display = 'none';
}
2) To hide only the Manager Attachments link use this
function onLoad(){
document.getElementById('header_attachment_list_label').style.display = 'none';
}
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
‎09-20-2022 05:38 AM
Hi Ankur,
Can you please help me in achieving this using ACL if possible
Usecase: To hide the manage attachments on the incident form when currently logged in user is part of selected assignment group
Thanks in advance!
Regards,
Swathi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-02-2023 02:52 AM
This seems to solve my problem but I want this to work on my view. I have restricted view created and if this view is on I want both attachment and manage should not be seen. How to write it for view?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-31-2020 10:19 PM
Hope you are doing good.
Let me know if I have answered your question.
If so, please mark appropriate response as correct & helpful so that this thread can be closed and others can be benefited by this.
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
‎11-02-2020 02:15 AM
Hi Ankur,
It is working as expected. Thanks.
Regards,
Hemanth