Hello friends I have a button in odoo which I want to be invisible when the 3 conditions are met:
<button class="oe_highlight" name="formview" type="object" string="Pagar" attrs="{'invisible':['|',('status_inv', '=',2),('validate_cheque', '=',False),('pay', '=',True)]}"/>
I have the invisible attribute in this way but it does not behave well.
if I replace it | by & odoo gives an error finally what I want is that it behaves like the AND operator if the 3 is fulfilled that is invisible
Try this :
<button class="oe_highlight" name="formview" type="object" string="Pagar" attrs="{'invisible':[('status_inv', '=',2),('validate_cheque', '=',False),('pay', '=',True)]}"/>
If no operator is declared, the '&' operator is put by default.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.