[英]inregularity in attrs odoo10
Hello friends I have a button in odoo which I want to be invisible when the 3 conditions are met:你好朋友我在odoo中有一个按钮,当满足3个条件时,我希望它不可见:
<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.我以这种方式具有 invisible 属性,但它表现不佳。
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
by & odoo 最后给出了一个错误我想要的是,如果 3 是不可见的,它的行为就像 AND 运算符
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.如果未声明运算符,则默认使用“&”运算符。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.