Hide UI Action when a field is empty
This content was last updated in 2020. It may still be useful, but could contain outdated information. Please confirm its accuracy before relying on it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 01:14 PM
Hi Community,
We have a field for "rejection reason" when a resource plan is rejected. I have configured it so this field shows when "Rejected" is selected, but because the workflow has already moved to "rejected" once the user sees the "reason" field, the email to let people know that it was rejected does not include the note.
Can I hide the UI Action until this field is filled in? Any other suggestions?
In the UI action, this code does not work:
function onCondition() {
$$('reject')[0].hide(); //This will hide the top button
$$('reject')[1].hide(); //This will hide the bottom button as well
}
function onCondition() {
$$('reject')[0].show(); //This will show the top button
$$('reject')[1].show(); //This will show the bottom button as well
}
Tried this also:
Thanks,
Heather
- Labels:
-
Resource Management
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 01:21 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 01:23 PM
in the condition field of UI action you can write something like this
current.<field_name> != ''; //replace <field_name> with actual field_name that you want to filled in.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 01:29 PM
Here is my condition-how do I capture this? u_rejection_reasonISNOTEMPTY
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 03:30 PM