In Odoo 9, I want to put a core field in a different page from the original.
Inside Inventory -> Product, the field is categ_id:
Original page = "Inventory"
Wanted page = "General Information"
I have this code:
<record id="product_template_only_form_view_extend" model="ir.ui.view">
<field name="name">product.template.product.form</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="product.product_template_only_form_view"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='categ_id']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>
<xpath expr="//field[@name='default_code']" position="after">
<field name="categ_id" string="Internal Category"/>
</xpath>
</field>
</record>
With the first xpath, I set invisible the field of Original page. That works.
With the second xpath, I show the categ_id field in the Wanted page. That works too, but the value is not modified in product_template model when I modify the value and press the save button.
Did I miss something?