ITSM Ui Policy hide filed based on onload
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2023 09:45 AM
Hi All,
I have two fields 1. required , 2. include . with scripting i am assigning the data inside the those two fields based on conditions . if condition 1 matches then field "required " will be auto populate some date with script . if condition 2 matches then "include" filed will auto populate some date .
I have written a Ui policy and if filed one(required )is empty then show the filed two and hide the filed one. if the field two (include ) is empty then filed two will be hide and field one will be visible .
I have tried but not working . Can any provide me the solution to the issue.
Thanks in Advance .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2023 10:25 AM
and UI Policy order is same or you tested after change it. If one is 100 then make the other one 110 and check it again.
What's result before and after.
Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2023 10:28 AM
@AshishKM
Ui policy order is not same one is 100 and another is 150
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2023 10:32 AM
Ok, what if both fields are not empty, try to print both value together via alert in onLoad script.
Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2023 10:54 AM
@AshishKM
for one filed when the form is loded i am getting undefined and for second i am gettkng the values so in this case i need to hide teh first filed and has to show only second filed .please let me know how can i do that
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2023 11:00 AM
It's undefined means not sure about empty, check the "auto populate" logic, that logic is setting some value may be some object.
find out this undefined mistry.
Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution