- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-07-2017 02:21 AM
Dear All,
Is there a way to make a section / tab of a form available, depending on the group?
Suppose, I am a member of ABC group. I log into the system and opens a particular form, which has 5 sections / tabs for 5 different group members. As per my requirement, when I log into the system and open the form, it should automatically select the ABC tab / section (say, it is the 3rd section / tab in the form), so that user need not to click on different tabs before opening the tabs related to his group.
Any help on this would be much appreciated.
Regards,
Sumana
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-08-2017 07:40 AM
Hi Sumana,
You can do it with a UI policy and a script include.
Script include:
Name: findUserGroup
Client callable: yes
UI Policy:
Several small things to note:
1. The line with the sys id: you can return the group name from the script include. However, if you change the group name for some reason, you will also have to change the ui policy script.
2. You will have to repeat lines 11-12 for each group, wahc each with its sys_id and position on the page.
3. The user must be in only one of the 5 groups, or, if in more than one, then the focus would be on the first group encountered. If you want to go through all of them, you'd need an array in the GlideAjax, and to split the array in your ui policy and find the right group.
harel
Edit:
I am sorry for the screen shots. When I try to paste the text itself, I get an error:
Your content could not be saved due to an error. You may have been logged out. If this problem persists please contact your system administrator. Click here to refresh this page.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-08-2017 03:24 PM
Then use the same method, but replace g_form.setSectionDisplay() with g_tabs2Sections.setActive(), similar to Harel's example.