Visibility of 'Confidential' field on Incident form
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-03-2018 07:52 AM
We have a field on Incident form "Confidential" and I have a requirement to control its visibility.
This field should be visible, if user CHANGES the Assignment group and he is a member of that group without saving the incident form
Please note, we already have one write and one read ACL which controls it's visibility but it works when the changes are saved.
I am thinking to write one Onchange client script to complete this task, if this is the solution, please help me with the code.
Thanks in Advance !
- Labels:
-
Incident Management
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-04-2018 07:06 AM
I already did this. But I am concerned about the condition
//This condition is not correct. I want to see onChange, if user is a member of assignment group then make the field visible.
if (g_user.isMemberOf(g_form.assignment_group))
{
g_form.setVisible('fieldname', true);
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-04-2018 07:13 AM
ismember of cannot be used in clienr script,
Look at this post to see how to use it in client side
https://community.servicenow.com/community?id=community_question&sys_id=18e01ba9dbdcdbc01dcaf3231f9619cd