Pular para o conteúdo
Menu
Esta pergunta foi sinalizada
1 Responder
11182 Visualizações

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
Cancelar
Melhor resposta

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
Cancelar
Autor

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.

Publicações relacionadas Respostas Visualizações Atividade
3
dez. 23
91444
3
set. 21
5381
1
set. 15
9087
4
ago. 25
6008
3
jul. 23
5930