Hide the field using business rule
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-17-2022 06:35 AM
Hi team,
my requirement is I have one choice field based on that field attachment field should visible while selecting choice field ,by using UI policy in new state I have written this it's working fine, my second requirement is attachment field should visible for one particular group but the attachment field is should not visible any groups in next state please help me on this .
I have written business rule (scratch pad), onload client script but it's not working:
function onLoad() {
var openedBy = g_form.getValue('opened_by');
if ( openedBy == g_user.userID || g_scratchpad.cost ) {
g_form.setDisplay('u_ach_bank_form', true);
g_form.setMandatory('u_ach_bank_form', true);
} else {
g_form.setMandatory('u_ach_bank_form', false);
g_form.setDisplay('u_ach_bank_form', false);
}
}
Thanks,
karishma

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-17-2022 06:41 AM
Add alert and see whether scratchpad is having correct value
alert(g_scratchpad.cost)
Also try setVisible instead of setDisplay function.
Thank you,
Palani
Palani
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-17-2022 06:42 AM
Hello karishma,
Why not create an additional condition in your UI Policy to show the attachment field based on your conditions?
Please mark my answer as correct/helpful if it has helped you.
Thanks,
Logan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-17-2022 06:54 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-17-2022 06:59 AM
Hello karishma,
Right, if this should only apply to one particular group what happens with a condition of Assignment Group is {Group}?
Please mark my answer as correct/helpful if it has helped you.
Thanks,
Logan