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

hi i have problem i want to hide field from my tree view but when i do this,
odoo tells me element cannot be located in parent view

field in my tree has filed name "virtual_available"

<record model="ir.ui.view" id="product_template_cabinet_form_tree_view">
<field name="name">product.template.cabinet</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="product.product_template_tree_view"/>
<field name="arch" type="xml">

<xpath expr="//field[@name='virtual_available']" position="attributes">
        <attribute name="invisible">1</attribute>
</xpath>


</field>

</record>
Avatar
Cancelar
Melhor resposta

May be this 'product.product_template_tree_view' view already inherited and the variable '
virtual_available' is added in that. Check wether the view already inherited and if yes then in '
inherit_id' field give that view's external id.

Avatar
Cancelar