How to show value of choice field based on if user is part of assignment group
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2025 10:52 AM
1. i have one choice field
field name: Request and
Values: hardware and software.
when user opens the form if user is part of hardware assignment group then software value should be visible in the field if user is not part of assignment group then hardware value in the field should not be visible
- Labels:
-
ITSM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-17-2025 04:56 AM
Hi @Ehab Pilloor
Thanks for your response,when i follow the above script and with correct assignment group name values in Request are not visible
but only hardware should not be visible when user is not part of hardware assignment group
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-17-2025 05:03 AM - edited 06-17-2025 05:04 AM
If assignment group values are not being fetched properly, you can try using sys ids of assignment groups.
grHardware.addQuery('group', 'SYSID_OF_HARDWARE_GRP');
grSoftware.addQuery('group', 'SYSID_OF_SOFTWARE_GRP');
This is not a best practice, check if it works this way and you can debug the previous script based on this.
Also double check every backend name in the code.