Files
manufacture/mrp_packaging_default/views/mrp_production_view.xml
Jairo Llopis 5b75b1bdc8 [ADD] mrp_packaging_default: product packaging data in MRP
This module allows and encourages the use of packaging within MRP, both to manufacture products or to create kits.

@moduon MT-4506
2023-12-22 10:43:48 +00:00

45 lines
1.7 KiB
XML

<?xml version="1.0" encoding="utf-8" ?>
<!-- Copyright 2023 Moduon Team S.L.
License LGPL-3.0 or later (https://www.gnu.org/licenses/lgpl-3.0) -->
<data>
<record id="mrp_production_form_view" model="ir.ui.view">
<field name="name">Product packaging</field>
<field name="model">mrp.production</field>
<field name="inherit_id" ref="mrp.mrp_production_form_view" />
<field name="arch" type="xml">
<xpath
expr="//field[@name='move_finished_ids']/tree/field[@name='product_uom_qty']"
position="before"
>
<field
name="product_packaging_id"
optional="show"
groups="product.group_stock_packaging"
/>
<field
name="product_packaging_qty"
optional="show"
groups="product.group_stock_packaging"
attrs="{'invisible': [('product_packaging_id', '=', False)]}"
/>
</xpath>
<xpath
expr="//field[@name='move_raw_ids']/tree/field[@name='product_uom_qty']"
position="before"
>
<field
name="product_packaging_id"
optional="show"
groups="product.group_stock_packaging"
/>
<field
name="product_packaging_qty"
optional="show"
groups="product.group_stock_packaging"
attrs="{'invisible': [('product_packaging_id', '=', False)]}"
/>
</xpath>
</field>
</record>
</data>