Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
11186 Vues

Hi,

How to make a field readonly based on some condition? For instance i want to make fields readonly on form load based on some values from another table.

Avatar
Ignorer
Meilleure réponse

Hello Binyam Assefa ,

 To make readonly field based on condition you can use "attrs" attribute in field tag as follows :

 <field name="field_name" attrs="{'readonly' : [domain]}"/>

 Hope this will work for you.

Thanks!

Avatar
Ignorer
Auteur

Thanks Jainesh Shah,

So i have to declare fields that contains some calculated values from another domains to use it here in the current view.

Publications associées Réponses Vues Activité
3
déc. 23
91448
3
sept. 21
5383
1
sept. 15
9088
4
août 25
6021
3
juil. 23
5930