<?xml version="1.0" encoding="utf-8"?>
<openerp>
    <data>
        <record id="view_production_lot_form_supplier" model="ir.ui.view">
            <field name="name">lot.supplier</field>
            <field name="model">stock.production.lot</field>
            <field name="inherit_id" ref="stock.view_production_lot_form"/>
            <field name="arch" type="xml">
                <xpath expr="//field[@name='product_id']" position="after">
                    <field name="supplier_id" readonly="1"/>
                    <field name="supplier_invoice_line_id" readonly="1"/>
                </xpath>
            </field>
        </record>
        <record id="view_lot_form_supplier_context" model="ir.ui.view">
            <field name="name">lot.supplier.context</field>
            <field name="model">stock.transfer_details</field>
            <field name="inherit_id" ref="stock.view_stock_enter_transfer_details"/>
            <field name="arch" type="xml">
                <xpath expr="//field[@name='item_ids']" position="before">
                    <field name="picking_id" invisible="1"/>
                </xpath>
                <xpath expr="//field[@name='item_ids']/tree/field[@name='lot_id']" position="attributes">
                    <attribute name="context">{'product_id': product_id,
                            'active_id': active_id}</attribute>
                </xpath>
            </field>
        </record>
    </data>
</openerp>
