Ir al contenido
Menú
Se marcó esta pregunta

states="done,ignore"

states="draft"

attrs="{'readonly':[('state','in',['done','ignore'])]}"

attrs="{'required':[('type','in',['sms'])],'invisible':[('type','in',['mail','chat'])]}"

Avatar
Descartar
Autor

in odoo17 attrs and states is no longer supported brother

Mejor respuesta

You can review the Documentation to learn about that changes

https://www.odoo.com/documentation/17.0/developer/reference/user_interface/view_architectures.html#semantic-components

Use readonly and required and invisible 



Avatar
Descartar
Mejor respuesta

You can give like this,

       attrs="{

           'readonly': [('state', 'in', ['done', 'ignore'])],

           'required': [('type', 'in', ['sms'])],

           'invisible': [('type', 'in', ['mail', 'chat'])],

           'string': 'Custom Label'

       }"/>

Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
0
abr 24
901
1
nov 24
774
0
ene 24
752
5
oct 24
2266
5
dic 24
5012