- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-14-2018 08:31 PM
Hi Developers,
I need to make a field(s_comments) visible on incident only if the Assignment group type="Supplier".
For this, I have written a UI policy on s_comments to hide it and a client script to control its visibility if the Assignment group type="Supplier". but its not working.
In client script I used the call back reference. Can any one let me know how can this be done?
Thanks in advance.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-14-2018 08:36 PM
Instead of client script, better dot walk Assignment Group to get the type in UI Policy condition builder something like below
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-14-2018 08:36 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-14-2018 09:29 PM
Hi Raju,
Its working as expected. Thanks a lot. It was simple but I was trying tough one.
But I m not getting why the tough one is not working..It was something as below. I tried(hardcoded) using sysID of group type Supplier but that was also not working...
Can u let me know whats wrong in below script:
function onChange(control, oldValue, newValue, isLoading, isTemplate) {
if (newValue === '') {
return;
}
var grp = g_form.getReference('assignment_group',doAlert);
//alert(grp.type.getDisplayValue());
function doAlert(grp) { //reference is passed into callback as first arguments
//alert(grp.type.getDisplayValue());
if(grp.type == 'Supplier')
{
//alert('Supplier'+grp.type);
g_form.setVisible('u_s_comments', true);
}
}
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2018 04:31 AM