How to set the visibility conditionally for multiple fields?

1
In my app I want to lock a group of fields based on an certain value. Of course (and that is what I did), you can change the editable parameter to conditionally and add an expression. This works fine. However, if you have multiple fields, you are repeating yourself a lot (DRY!). Is there a way to do this differently? It would be great if you could have a container or even a data view that is editable based on a condition.  Hope someone has a clever solution!
asked
2 answers
2

Good one for an idea. You would have my vote. But that is no solution for now.

Andrej’ suggestion is a good one: Put them in a separate entity.

Other option is to set editability via the write-option in the access rules. But that is a general setting so only useful if those fields are always having the same editable-status. I doubt that this is useful for your challenge.

The easiest way is to add two containers setting the visibility according to opposing expressions and one container having each element set editable to ‘yes’ and the other container having each element set editable to ‘no’ 

 

answered
0

How about creating two containers: one with the attributes editable and one with the attributes non-editable. Set the conditional visibility of the containers based on your requirements.

answered