mirror of
https://github.com/OCA/manufacture.git
synced 2025-01-28 16:37:15 +02:00
53 lines
2.3 KiB
XML
53 lines
2.3 KiB
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<odoo>
|
|
<record id="product_template_only_form_view_bomlines" model="ir.ui.view">
|
|
<field name="model">product.template</field>
|
|
<field name="inherit_id" ref="product.product_template_only_form_view" />
|
|
<field name="arch" type="xml">
|
|
<xpath expr="//notebook" position="inside">
|
|
<page name="bom_line" string="Bill of Materials">
|
|
<div
|
|
attrs="{'invisible': [('bom_count', '<', 2)]}"
|
|
class="alert alert-danger text-center"
|
|
role="alert"
|
|
>
|
|
<p
|
|
>The product is linked to several BoMs, modifications must be done BoM-side.</p>
|
|
</div>
|
|
<div
|
|
attrs="{'invisible': [('bom_count', '!=', 0)]}"
|
|
class="alert alert-danger text-center"
|
|
role="alert"
|
|
>
|
|
<p
|
|
>The product doesn't have a BoM yet, you must create one before updating its components.</p>
|
|
<button
|
|
name="button_create_bom"
|
|
type="object"
|
|
string="Create BoM"
|
|
/>
|
|
</div>
|
|
<field
|
|
name="specific_bom_line_ids"
|
|
attrs="{'invisible': [('bom_count', '!=', 1)]}"
|
|
>
|
|
<tree editable="bottom">
|
|
<field name="company_id" invisible="1" />
|
|
<field name="product_id" />
|
|
<field name="product_qty" />
|
|
<field
|
|
name="possible_bom_product_template_attribute_value_ids"
|
|
invisible="1"
|
|
/>
|
|
<field
|
|
name="bom_product_template_attribute_value_ids"
|
|
widget="many2many_tags"
|
|
/>
|
|
</tree>
|
|
</field>
|
|
</page>
|
|
</xpath>
|
|
</field>
|
|
</record>
|
|
</odoo>
|