Files
odoo_source/addons/purchase_requisition/views/product_views.xml
T
Hetal Dhanak ca3e898481 [IMP] purchase, purchase_requisition: supplier.info tree view
* use an editable tree to edit the supplier info
* keep the original forms because they're used in the "vendor pricelist"
menuitem
* updated tour
* change the position of requisition_id

Task-2029380

closes odoo/odoo#35972

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-10-16 09:44:51 +00:00

50 lines
2.0 KiB
XML

<?xml version="1.0"?>
<odoo>
<record id="product_supplierinfo_tree_view_inherit" model="ir.ui.view">
<field name="name">product.template.product.form.inherit</field>
<field name="model">product.supplierinfo</field>
<field name="inherit_id" ref="product.product_supplierinfo_tree_view"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='product_id']" position="after">
<field name="purchase_requisition_id" readonly="1" optional="hide"/>
</xpath>
</field>
</record>
<record id="supplier_info_form_inherit" model="ir.ui.view">
<field name="name">product.supplierinfo.requisition.view</field>
<field name="model">product.supplierinfo</field>
<field name="priority">20</field>
<field name="inherit_id" ref="product.product_supplierinfo_form_view"/>
<field name="arch" type="xml">
<field name="product_code" position="after">
<field name="purchase_requisition_id"
attrs="{'invisible': [('purchase_requisition_id', '=', False)]}"/>
</field>
</field>
</record>
<record id="product_template_form_view_inherit" model="ir.ui.view">
<field name="name">product.template.form.inherit</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="purchase.view_product_supplier_inherit"/>
<field name="arch" type="xml">
<group name="bill" position="before">
<group string="Reordering" attrs="{'invisible': [('type', '=', 'service')]}">
<field name="purchase_requisition" widget="radio"/>
</group>
</group>
</field>
</record>
<act_window
id="act_res_partner_2_purchase_order"
name="Purchase orders"
domain="[('requisition_id', '=', active_id)]"
context="{'default_requisition_id': active_id}"
res_model="purchase.order"
binding_model="purchase.requisition" binding_views="form"/>
</odoo>