ITSM Ui Policy hide filed based on onload

sushma9
Tera Contributor

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 .

 

 

 

12 REPLIES 12

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

sushma9
Tera Contributor

@AshishKM 
Ui policy order is  not same one is 100 and another is 150

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

sushma9
Tera Contributor

@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

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