UI policy (not working) and Data Policy (Working)

Andi Hoxha
Tera Contributor

Hello, I am trying to make fields attestation and attestation group readable only when the state is attested. However, when I applied UI policy is not working. The only thing that seems to be working is the data policy(used as UI policy on clients). Can someone help me understand what is the reason that the UI policy is not working for my case to make the fields readable.

Below I have attached a screenshot of both of them.

UI policy:

forum ui policy 1.png

Data policy:

data policy forum 1.png

I also tried to investigate online and if the issues found there would be similar with mine. So far I have no idea why that UI policy is not working. Only thing I realised is when I used client script it did not work as well.

 

2 ACCEPTED SOLUTIONS

ersureshbe
Giga Sage
Giga Sage

Hi, I recommend to check with the UI Policy order.  The fields are mentioned under UI Policy action may used some other UI policies and order will be the same.

Regards,
Suresh.

View solution in original post

Saurav11
Kilo Patron
Kilo Patron

Hello,

 

Just to be sure the fields are not getting read only on list or form? If it is list view UI policy does not work in list view.

 

If it is form view check if there are any other UI policy on the same field? also try to make the order of the UI policy 1000.

 

Please mark my answer as correct based on Impact.

View solution in original post

9 REPLIES 9

@Andi Hoxha 

is data policy required? It's only required when there is API integration

Try creating the UI policy again as fresh.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

No data policy is not required but it solved the solution for now. What bothers me is why the UI policy does not work. I mean I would prefer to use UI policy rather than data policy as a best practice to make a field readable.

 

@Andi Hoxha 

Ideally UI policy should work fine.

 

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

ersureshbe
Giga Sage
Giga Sage

Hi, I recommend to check with the UI Policy order.  The fields are mentioned under UI Policy action may used some other UI policies and order will be the same.

Regards,
Suresh.

Saurav11
Kilo Patron
Kilo Patron

Hello,

 

Just to be sure the fields are not getting read only on list or form? If it is list view UI policy does not work in list view.

 

If it is form view check if there are any other UI policy on the same field? also try to make the order of the UI policy 1000.

 

Please mark my answer as correct based on Impact.