- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2023 02:13 AM
Hi All,
I have a requirement to Hide the Incident fields(from form and list view) from the table itself.
Condition is - Fields from incident ticket like short_description, description should be hidden, which are set to Region = Europe.
It should be a server side script like ACL so it should not a have any delay hiding the fields.
Please let me know how I can achieve this requirement.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2023 03:28 AM
@Omkar Jori add below code in script section. Replace u_region with your region field name.
if (current.u_region == 'Europe')
answer = false;
.If I could help you with your Query then, please hit the Thumb Icon and mark as Correct !!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-21-2023 03:38 AM
Hi @Omkar Jori ,
Hope you are doing great.
solution to hide specific Incident fields based on the Region condition:
Create a Business Rule that will execute whenever an Incident record is displayed on the form or list view.
Check Region Condition: In the Business Rule script, we'll check if the Region field is set to "Europe" for the current Incident record.
Hide Fields: If the Region is "Europe," we'll use a script to hide the desired fields like short_description and description from the form and list view.
(function executeRule(current, previous /*, gs */) {
// Check if Region is set to "Europe"
if (current.region == 'Europe') {
// Hide fields from the Incident form view
current.setDisplayValue('short_description', '');
current.setDisplayValue('description', '');
}
})(current, previous);
Regards,
Riya Verma