<commit_before><openerp>
    <data>
        <!-- Delivery Carriers -->
        <menuitem id="menu_delivery" name="Delivery" parent="stock.menu_stock_config_settings" groups="stock.group_stock_manager" sequence="50"/>
        <menuitem id="sale_menu_delivery" name="Delivery" parent="base.menu_sale_config" groups="base.group_sale_manager" sequence="12"/>

        <record id="view_delivery_carrier_tree" model="ir.ui.view">
            <field name="name">delivery.carrier.tree</field>
            <field name="model">delivery.carrier</field>
            <field name="arch" type="xml">
                <tree string="Carrier">
                    <field name="sequence" widget="handle"/>
                    <field name="name"/>
                    <field name="partner_id"/>
                    <field name="price" invisible="'order_id' not in context"/>
                </tree>
            </field>
        </record>

        <record id="view_delivery_carrier_form" model="ir.ui.view">
            <field name="name">delivery.carrier.form</field>
            <field name="model">delivery.carrier</field>
            <field name="arch" type="xml">
                <form string="Carrier">
                    <div class="oe_title">
                        <label for="name" class="oe_edit_only"/>
                        <h1>
                            <field name="name"/>
                        </h1>
                    </div>
                    <group>
                        <field name="active"/>
                    </group>
                    <group name="general">
                        <group string="General Information">
                            <field name="partner_id"/>
                            <field name="product_id"/>
                            <field name="delivery_type"/>
                        </group>
                        <group string="Pricing Information" name='pricing_info' attrs="{'invisible':[('delivery_type','!=','grid')]}">
                            <field name="normal_price" attrs="{'readonly':[('use_detailed_pricelist', '=', True)]}"/>
                            <label for="free_if_more_than"/>
                            <div>
                                <field name="free_if_more_than" attrs="{'readonly':[('use_detailed_pricelist', '=', True)]}"/>
                                <field name="amount" attrs="{'required':[('free_if_more_than','&lt;&gt;',False)], 'invisible':[('free_if_more_than','=',False)]}"/>
                            </div>
                            <field name="use_detailed_pricelist"/>
                        </group>
                    </group>

                    <field name="pricelist_ids" attrs="{'invisible':[('use_detailed_pricelist','=',False)]}" mode="tree">
                        <tree string="Delivery grids">
                              <field name="sequence"/>
                              <field name="name"/>
                        </tree>
                        <form string="Delivery grids">
                             <group>
                                <group>
                                    <field name="name"/>
                                </group>
                                <group>
                                    <field name="active"/>
                                    <field name="sequence"/>
                                </group>
                             </group>
                             <notebook>
                                <page string="Grid definition">
                                   <field name="line_ids"/>
                                </page>
                                <page string="Destination">
                                    <group>
                                        <group>
                                            <field name="country_ids" widget="many2many_tags"/>
                                            <field name="state_ids" widget="many2many_tags"/>
                                        </group>
                                        <group>
                                            <label for="zip_from" string="Zip"/>
                                            <div>
                                                <field name="zip_from" class="oe_inline"/>
                                                -
                                                <field name="zip_to" class="oe_inline"/>
                                            </div>
                                        </group>
                                    </group>
                                </page>
                            </notebook>
                        </form>
                   </field>
                </form>
            </field>
        </record>

        <record id="action_delivery_carrier_form" model="ir.actions.act_window">
            <field name="name">Delivery Methods</field>
            <field name="type">ir.actions.act_window</field>
            <field name="res_model">delivery.carrier</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
            <field name="help" type="html">
              <p class="oe_view_nocontent_create">
                Click to define a new delivery method.
              </p><p>
                Each carrier (e.g. UPS) can have several delivery methods (e.g.
                UPS Express, UPS Standard) with a set of pricing rules attached
                to each method.
              </p><p>
                These methods allow to automatically compute the delivery price
                according to your settings; on the sales order (based on the
                quotation) or the invoice (based on the delivery orders).
              </p>
            </field>
        </record>

        <menuitem action="action_delivery_carrier_form" id="menu_action_delivery_carrier_form" parent="menu_delivery" sequence="1"/>
        <menuitem action="action_delivery_carrier_form" id="sale_menu_action_delivery_carrier_form" parent="sale_menu_delivery" sequence="1"/>

        <!-- Delivery Grids -->
        <record id="view_delivery_grid_tree" model="ir.ui.view">
            <field name="name">delivery.grid.tree</field>
            <field name="model">delivery.grid</field>
            <field name="arch" type="xml">
                <tree string="Delivery grids">
                    <field name="sequence"/>
                    <field name="carrier_id"/>
                    <field name="name"/>
                </tree>
            </field>
        </record>

        <record id="view_delivery_grid_form" model="ir.ui.view">
            <field name="name">delivery.grid.form</field>
            <field name="model">delivery.grid</field>
            <field name="arch" type="xml">
                <form string="Delivery grids">
                    <group col="4">
                        <field name="name"/>
                        <field name="active"/>
                        <field name="carrier_id"/>
                        <field name="sequence"/>
                    </group>
                    <notebook>
                        <page string="Grid definition">
                            <field name="line_ids"/>
                        </page>
                        <page string="Destination">
                            <group string="Countries">
                                <field name="country_ids" nolabel="1"/>
                            </group>
                            <group string="States">
                                <field colspan="2" name="state_ids" nolabel="1"/>
                                <field name="zip_from"/>
                                <field name="zip_to"/>
                            </group>
                        </page>
                    </notebook>
                </form>
            </field>
        </record>
        <record id="action_delivery_grid_form" model="ir.actions.act_window">
            <field name="name">Delivery Pricelist</field>
            <field name="type">ir.actions.act_window</field>
            <field name="res_model">delivery.grid</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
            <field name="help" type="html">
              <p class="oe_view_nocontent_create">
                Click to create a delivery price list for a specific region.
              </p><p>
                The delivery price list allows you to compute the cost and
                sales price of the delivery according to the weight of the
                products and other criteria. You can define several price lists
                for each delivery method: per country or a zone in a specific
                country defined by a postal code range.
              </p>
            </field>
        </record>
        <menuitem action="action_delivery_grid_form" id="menu_action_delivery_grid_form" parent="menu_delivery" sequence="2"/>
        <menuitem action="action_delivery_grid_form" id="sale_menu_action_delivery_grid_form" parent="sale_menu_delivery" sequence="2"/>

        <record id="view_delivery_grid_line_form" model="ir.ui.view">
            <field name="name">delivery.grid.line.form</field>
            <field name="model">delivery.grid.line</field>
            <field name="arch" type="xml">
                <form string="Grid Lines">
                    <group>
                        <field name="name"/>
                        <field name="sequence"/>
                    </group>
                    <group>
                        <group>
                            <label for="type" string="Condition"/>
                            <div>
                                <field name="type" class="oe_inline"/>
                                <field name="operator" class="oe_inline"/>
                                <field name="max_value" class="oe_inline"/>
                            </div>
                            <label for="price_type"/>
                            <div>
                                <field name="price_type" class="oe_inline"/>
                                <label string=" in Function of " class="oe_inline" attrs="{'invisible':[('price_type','=','fixed')]}"/>
                                <field name="variable_factor" attrs="{'invisible':[('price_type','=','fixed')]}" class="oe_inline"/>
                            </div>
                        </group>
                        <group>
                            <field name="list_price"/>
                            <field name="standard_price"/>
                        </group>
                    </group>
                </form>
            </field>
        </record>
        <record id="view_delivery_grid_line_tree" model="ir.ui.view">
            <field name="name">delivery.grid.line.tree</field>
            <field name="model">delivery.grid.line</field>
            <field name="arch" type="xml">
                <tree string="Grid Lines">
                    <field name="sequence" widget="handle" />
                    <field name="name"/>
                    <field name="type"/>
                    <field name="operator"/>
                    <field name="max_value" nolabel="1"/>
                    <field name="list_price"/>
                    <field name="standard_price"/>
                </tree>
            </field>
        </record>

        <record id="view_picking_withcarrier_out_form" model="ir.ui.view">
            <field name="name">delivery.stock.picking_withcarrier.form.view</field>
            <field name="model">stock.picking</field>
            <field name="inherit_id" ref="stock.view_picking_form"/>
            <field name="arch" type="xml">
              <data>
                <xpath expr="//page[@name='extra']" position="inside">
                <separator string="Carrier Information"/>
                <group>
                    <group name='carrier_data'>
                        <field name="carrier_id"/>
                        <field name="delivery_type" attrs="{'invisible':True}"/>
                        <label for="carrier_tracking_ref"/>
                        <div>
                            <field name="carrier_tracking_ref" class="oe_inline"/>
                            <button type='object' class="fa fa-arrow-right oe_link" name="cancel_shipment" string="Cancel" attrs="{'invisible':['|','|','|',('carrier_tracking_ref','=',False),('delivery_type','=','grid'),('delivery_type','=',False),('state','not in',('done'))]}"/>
                        </div>
                        <field name="carrier_price"/>
                    </group>
                    <group>
                        <label for="weight" string="Weight"/>
                        <div>
                            <field name="weight" class="oe_inline"/>
                            <field name="weight_uom_id" nolabel="1" class="oe_inline"/>
                        </div>
                        <field name="weight_net" groups="base.group_no_one"/>
                        <field name="number_of_packages"/>
                    </group>
                </group>
                </xpath>
                <xpath expr="//h1" position="before">
                    <div class="oe_right oe_button_box">
                        <button type="object" name="open_website_url" class="oe_stat_button" icon='fa-truck' string="Tracking" attrs="{'invisible': ['|',('carrier_tracking_ref','=',False),('delivery_type','=','grid')]}" />
                    </div>
                </xpath>
                <xpath expr="/form/header/button[last()]" position="after">
                    <button name="send_to_shipper" string="Send to Shipper" type="object" attrs="{'invisible':['|','|','|',('carrier_tracking_ref','!=',False),('delivery_type','=','grid'),('delivery_type','=',False),('state','not in',('done'))]}"/>
                </xpath>
              </data>
            </field>
        </record>

        <record id="action_picking_tree" model="ir.actions.act_window">
            <field name="name">Picking to be invoiced</field>
            <field name="res_model">stock.picking</field>
            <field name="type">ir.actions.act_window</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
            <field name="domain">[('invoice_state','=','2binvoiced'),('state','=','done'),('type','=','out')]</field>
            <field name="filter" eval="True"/>
            <field name="context">{'default_invoice_state': '2binvoiced', 'default_type': 'out', 'contact_display': 'partner'}</field>
            <field name="search_view_id" eval="False"/>
        </record>

        <record id="view_picking_withweight_internal_move_form" model="ir.ui.view">
            <field name="name">stock.picking_withweight.internal.move.form.view</field>
            <field name="model">stock.move</field>
            <field name="inherit_id" ref="stock.view_move_picking_form"/>
            <field name="arch" type="xml">
                <xpath expr="//field[@name='date_expected']" position="after">
                    <field name="weight"/>
                    <field name="weight_net" groups="base.group_no_one"/>
                </xpath>
            </field>
        </record>

        <record id="view_move_withweight_form" model="ir.ui.view">
            <field name="name">stock.move.form.weight</field>
            <field name="model">stock.move</field>
            <field name="inherit_id" ref="stock.view_move_form"/>
            <field name="arch" type="xml">
                <xpath expr="//group[@name='main_grp']" position="inside">
                    <group>
                        <label for="weight"/>
                        <div>
                            <field name="weight" nolabel="1" class="oe_inline"/>
                            <field name="weight_uom_id" nolabel="1" class="oe_inline"/>
                        </div>
                        <field name="weight_net" groups="base.group_no_one"/>
                    </group>
                </xpath>
            </field>
        </record>

        <record id="view_order_form_with_carrier" model="ir.ui.view">
            <field name="name">delivery.sale.order.form.view.with_carrier</field>
            <field name="model">sale.order</field>
            <field name="inherit_id" ref="sale.view_order_form"/>
            <field name="arch" type="xml">
                <data>
                  <xpath expr="//field[@name='payment_term_id']" position="after">
                      <field name="id" invisible="1"/>
                      <label for="carrier_id"/>
                      <div name='carrier_selection'>
                          <field name="carrier_id" context="{'order_id': id}" class="oe_inline"/>
                          <button name="delivery_set" string="Set price" type="object" class="fa fa-arrow-right oe_link" attrs="{'invisible':['|',('carrier_id','=',False),('state','not in',('draft','sent'))]}"/>
                      </div>
                  </xpath>
                  <xpath expr="//div[@name='carrier_selection']" position="after">
                      <field name='delivery_price' widget='monetary' options="{'currency_field': 'currency_id'}"/>
                  </xpath>
                </data>
            </field>
        </record>

        <record id="view_picking_withcarrier_out_form_shipping" model="ir.ui.view">
            <field name="name">delivery.stock.picking_withcarrier.form.view.shipping</field>
            <field name="model">stock.picking</field>
            <field name="inherit_id" ref="delivery.view_picking_withcarrier_out_form"/>
            <field name="arch" type="xml">
                <xpath expr='//group[@name="carrier_data"]' position='replace'>
                    <group name='carrier_data'>
                      <field name="carrier_id"/>
                      <field name="delivery_type" attrs="{'invisible':True}"/>
                      <label for="carrier_tracking_ref"/>
                      <div>
                          <field name="carrier_tracking_ref" class="oe_inline"/>
                          <button type='object' class="fa fa-arrow-right oe_link" name="cancel_shipment" string="Cancel" attrs="{'invisible':['|','|','|',('carrier_tracking_ref','=',False),('delivery_type','=','grid'),('delivery_type','=',False),('state','not in',('done'))]}"/>
                      </div>
                      <field name="carrier_price"/>
                    </group>
                </xpath>
            </field>
        </record>

    </data>
</openerp>
<commit_msg>[IMP] delivery : put the delivery carrier form view into a sheet<commit_after><openerp>
    <data>
        <!-- Delivery Carriers -->
        <menuitem id="menu_delivery" name="Delivery" parent="stock.menu_stock_config_settings" groups="stock.group_stock_manager" sequence="50"/>
        <menuitem id="sale_menu_delivery" name="Delivery" parent="base.menu_sale_config" groups="base.group_sale_manager" sequence="12"/>

        <record id="view_delivery_carrier_tree" model="ir.ui.view">
            <field name="name">delivery.carrier.tree</field>
            <field name="model">delivery.carrier</field>
            <field name="arch" type="xml">
                <tree string="Carrier">
                    <field name="sequence" widget="handle"/>
                    <field name="name"/>
                    <field name="partner_id"/>
                    <field name="price" invisible="'order_id' not in context"/>
                </tree>
            </field>
        </record>

        <record id="view_delivery_carrier_form" model="ir.ui.view">
            <field name="name">delivery.carrier.form</field>
            <field name="model">delivery.carrier</field>
            <field name="arch" type="xml">
                <form string="Carrier">
                    <sheet>
                    <div class="oe_title">
                        <label for="name" class="oe_edit_only"/>
                        <h1>
                            <field name="name"/>
                        </h1>
                    </div>
                    <group>
                        <field name="active"/>
                    </group>
                    <group name="general">
                        <group string="General Information">
                            <field name="partner_id"/>
                            <field name="product_id"/>
                            <field name="delivery_type"/>
                        </group>
                        <group string="Pricing Information" name='pricing_info' attrs="{'invisible':[('delivery_type','!=','grid')]}">
                            <field name="normal_price" attrs="{'readonly':[('use_detailed_pricelist', '=', True)]}"/>
                            <label for="free_if_more_than"/>
                            <div>
                                <field name="free_if_more_than" attrs="{'readonly':[('use_detailed_pricelist', '=', True)]}"/>
                                <field name="amount" attrs="{'required':[('free_if_more_than','&lt;&gt;',False)], 'invisible':[('free_if_more_than','=',False)]}"/>
                            </div>
                            <field name="use_detailed_pricelist"/>
                        </group>
                    </group>

                    <field name="pricelist_ids" attrs="{'invisible':[('use_detailed_pricelist','=',False)]}" mode="tree">
                        <tree string="Delivery grids">
                              <field name="sequence"/>
                              <field name="name"/>
                        </tree>
                        <form string="Delivery grids">
                             <group>
                                <group>
                                    <field name="name"/>
                                </group>
                                <group>
                                    <field name="active"/>
                                    <field name="sequence"/>
                                </group>
                             </group>
                             <notebook>
                                <page string="Grid definition">
                                   <field name="line_ids"/>
                                </page>
                                <page string="Destination">
                                    <group>
                                        <group>
                                            <field name="country_ids" widget="many2many_tags"/>
                                            <field name="state_ids" widget="many2many_tags"/>
                                        </group>
                                        <group>
                                            <label for="zip_from" string="Zip"/>
                                            <div>
                                                <field name="zip_from" class="oe_inline"/>
                                                -
                                                <field name="zip_to" class="oe_inline"/>
                                            </div>
                                        </group>
                                    </group>
                                </page>
                            </notebook>
                        </form>
                   </field>
                   </sheet>
                </form>
            </field>
        </record>

        <record id="action_delivery_carrier_form" model="ir.actions.act_window">
            <field name="name">Delivery Methods</field>
            <field name="type">ir.actions.act_window</field>
            <field name="res_model">delivery.carrier</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
            <field name="help" type="html">
              <p class="oe_view_nocontent_create">
                Click to define a new delivery method.
              </p><p>
                Each carrier (e.g. UPS) can have several delivery methods (e.g.
                UPS Express, UPS Standard) with a set of pricing rules attached
                to each method.
              </p><p>
                These methods allow to automatically compute the delivery price
                according to your settings; on the sales order (based on the
                quotation) or the invoice (based on the delivery orders).
              </p>
            </field>
        </record>

        <menuitem action="action_delivery_carrier_form" id="menu_action_delivery_carrier_form" parent="menu_delivery" sequence="1"/>
        <menuitem action="action_delivery_carrier_form" id="sale_menu_action_delivery_carrier_form" parent="sale_menu_delivery" sequence="1"/>

        <!-- Delivery Grids -->
        <record id="view_delivery_grid_tree" model="ir.ui.view">
            <field name="name">delivery.grid.tree</field>
            <field name="model">delivery.grid</field>
            <field name="arch" type="xml">
                <tree string="Delivery grids">
                    <field name="sequence"/>
                    <field name="carrier_id"/>
                    <field name="name"/>
                </tree>
            </field>
        </record>

        <record id="view_delivery_grid_form" model="ir.ui.view">
            <field name="name">delivery.grid.form</field>
            <field name="model">delivery.grid</field>
            <field name="arch" type="xml">
                <form string="Delivery grids">
                    <group col="4">
                        <field name="name"/>
                        <field name="active"/>
                        <field name="carrier_id"/>
                        <field name="sequence"/>
                    </group>
                    <notebook>
                        <page string="Grid definition">
                            <field name="line_ids"/>
                        </page>
                        <page string="Destination">
                            <group string="Countries">
                                <field name="country_ids" nolabel="1"/>
                            </group>
                            <group string="States">
                                <field colspan="2" name="state_ids" nolabel="1"/>
                                <field name="zip_from"/>
                                <field name="zip_to"/>
                            </group>
                        </page>
                    </notebook>
                </form>
            </field>
        </record>
        <record id="action_delivery_grid_form" model="ir.actions.act_window">
            <field name="name">Delivery Pricelist</field>
            <field name="type">ir.actions.act_window</field>
            <field name="res_model">delivery.grid</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
            <field name="help" type="html">
              <p class="oe_view_nocontent_create">
                Click to create a delivery price list for a specific region.
              </p><p>
                The delivery price list allows you to compute the cost and
                sales price of the delivery according to the weight of the
                products and other criteria. You can define several price lists
                for each delivery method: per country or a zone in a specific
                country defined by a postal code range.
              </p>
            </field>
        </record>
        <menuitem action="action_delivery_grid_form" id="menu_action_delivery_grid_form" parent="menu_delivery" sequence="2"/>
        <menuitem action="action_delivery_grid_form" id="sale_menu_action_delivery_grid_form" parent="sale_menu_delivery" sequence="2"/>

        <record id="view_delivery_grid_line_form" model="ir.ui.view">
            <field name="name">delivery.grid.line.form</field>
            <field name="model">delivery.grid.line</field>
            <field name="arch" type="xml">
                <form string="Grid Lines">
                    <group>
                        <field name="name"/>
                        <field name="sequence"/>
                    </group>
                    <group>
                        <group>
                            <label for="type" string="Condition"/>
                            <div>
                                <field name="type" class="oe_inline"/>
                                <field name="operator" class="oe_inline"/>
                                <field name="max_value" class="oe_inline"/>
                            </div>
                            <label for="price_type"/>
                            <div>
                                <field name="price_type" class="oe_inline"/>
                                <label string=" in Function of " class="oe_inline" attrs="{'invisible':[('price_type','=','fixed')]}"/>
                                <field name="variable_factor" attrs="{'invisible':[('price_type','=','fixed')]}" class="oe_inline"/>
                            </div>
                        </group>
                        <group>
                            <field name="list_price"/>
                            <field name="standard_price"/>
                        </group>
                    </group>
                </form>
            </field>
        </record>
        <record id="view_delivery_grid_line_tree" model="ir.ui.view">
            <field name="name">delivery.grid.line.tree</field>
            <field name="model">delivery.grid.line</field>
            <field name="arch" type="xml">
                <tree string="Grid Lines">
                    <field name="sequence" widget="handle" />
                    <field name="name"/>
                    <field name="type"/>
                    <field name="operator"/>
                    <field name="max_value" nolabel="1"/>
                    <field name="list_price"/>
                    <field name="standard_price"/>
                </tree>
            </field>
        </record>

        <record id="view_picking_withcarrier_out_form" model="ir.ui.view">
            <field name="name">delivery.stock.picking_withcarrier.form.view</field>
            <field name="model">stock.picking</field>
            <field name="inherit_id" ref="stock.view_picking_form"/>
            <field name="arch" type="xml">
              <data>
                <xpath expr="//page[@name='extra']" position="inside">
                <separator string="Carrier Information"/>
                <group>
                    <group name='carrier_data'>
                        <field name="carrier_id"/>
                        <field name="delivery_type" attrs="{'invisible':True}"/>
                        <label for="carrier_tracking_ref"/>
                        <div>
                            <field name="carrier_tracking_ref" class="oe_inline"/>
                            <button type='object' class="fa fa-arrow-right oe_link" name="cancel_shipment" string="Cancel" attrs="{'invisible':['|','|','|',('carrier_tracking_ref','=',False),('delivery_type','=','grid'),('delivery_type','=',False),('state','not in',('done'))]}"/>
                        </div>
                        <field name="carrier_price"/>
                    </group>
                    <group>
                        <label for="weight" string="Weight"/>
                        <div>
                            <field name="weight" class="oe_inline"/>
                            <field name="weight_uom_id" nolabel="1" class="oe_inline"/>
                        </div>
                        <field name="weight_net" groups="base.group_no_one"/>
                        <field name="number_of_packages"/>
                    </group>
                </group>
                </xpath>
                <xpath expr="//h1" position="before">
                    <div class="oe_right oe_button_box">
                        <button type="object" name="open_website_url" class="oe_stat_button" icon='fa-truck' string="Tracking" attrs="{'invisible': ['|',('carrier_tracking_ref','=',False),('delivery_type','=','grid')]}" />
                    </div>
                </xpath>
                <xpath expr="/form/header/button[last()]" position="after">
                    <button name="send_to_shipper" string="Send to Shipper" type="object" attrs="{'invisible':['|','|','|',('carrier_tracking_ref','!=',False),('delivery_type','=','grid'),('delivery_type','=',False),('state','not in',('done'))]}"/>
                </xpath>
              </data>
            </field>
        </record>

        <record id="action_picking_tree" model="ir.actions.act_window">
            <field name="name">Picking to be invoiced</field>
            <field name="res_model">stock.picking</field>
            <field name="type">ir.actions.act_window</field>
            <field name="view_type">form</field>
            <field name="view_mode">tree,form</field>
            <field name="domain">[('invoice_state','=','2binvoiced'),('state','=','done'),('type','=','out')]</field>
            <field name="filter" eval="True"/>
            <field name="context">{'default_invoice_state': '2binvoiced', 'default_type': 'out', 'contact_display': 'partner'}</field>
            <field name="search_view_id" eval="False"/>
        </record>

        <record id="view_picking_withweight_internal_move_form" model="ir.ui.view">
            <field name="name">stock.picking_withweight.internal.move.form.view</field>
            <field name="model">stock.move</field>
            <field name="inherit_id" ref="stock.view_move_picking_form"/>
            <field name="arch" type="xml">
                <xpath expr="//field[@name='date_expected']" position="after">
                    <field name="weight"/>
                    <field name="weight_net" groups="base.group_no_one"/>
                </xpath>
            </field>
        </record>

        <record id="view_move_withweight_form" model="ir.ui.view">
            <field name="name">stock.move.form.weight</field>
            <field name="model">stock.move</field>
            <field name="inherit_id" ref="stock.view_move_form"/>
            <field name="arch" type="xml">
                <xpath expr="//group[@name='main_grp']" position="inside">
                    <group>
                        <label for="weight"/>
                        <div>
                            <field name="weight" nolabel="1" class="oe_inline"/>
                            <field name="weight_uom_id" nolabel="1" class="oe_inline"/>
                        </div>
                        <field name="weight_net" groups="base.group_no_one"/>
                    </group>
                </xpath>
            </field>
        </record>

        <record id="view_order_form_with_carrier" model="ir.ui.view">
            <field name="name">delivery.sale.order.form.view.with_carrier</field>
            <field name="model">sale.order</field>
            <field name="inherit_id" ref="sale.view_order_form"/>
            <field name="arch" type="xml">
                <data>
                  <xpath expr="//field[@name='payment_term_id']" position="after">
                      <field name="id" invisible="1"/>
                      <label for="carrier_id"/>
                      <div name='carrier_selection'>
                          <field name="carrier_id" context="{'order_id': id}" class="oe_inline"/>
                          <button name="delivery_set" string="Set price" type="object" class="fa fa-arrow-right oe_link" attrs="{'invisible':['|',('carrier_id','=',False),('state','not in',('draft','sent'))]}"/>
                      </div>
                  </xpath>
                  <xpath expr="//div[@name='carrier_selection']" position="after">
                      <field name='delivery_price' widget='monetary' options="{'currency_field': 'currency_id'}"/>
                  </xpath>
                </data>
            </field>
        </record>

        <record id="view_picking_withcarrier_out_form_shipping" model="ir.ui.view">
            <field name="name">delivery.stock.picking_withcarrier.form.view.shipping</field>
            <field name="model">stock.picking</field>
            <field name="inherit_id" ref="delivery.view_picking_withcarrier_out_form"/>
            <field name="arch" type="xml">
                <xpath expr='//group[@name="carrier_data"]' position='replace'>
                    <group name='carrier_data'>
                      <field name="carrier_id"/>
                      <field name="delivery_type" attrs="{'invisible':True}"/>
                      <label for="carrier_tracking_ref"/>
                      <div>
                          <field name="carrier_tracking_ref" class="oe_inline"/>
                          <button type='object' class="fa fa-arrow-right oe_link" name="cancel_shipment" string="Cancel" attrs="{'invisible':['|','|','|',('carrier_tracking_ref','=',False),('delivery_type','=','grid'),('delivery_type','=',False),('state','not in',('done'))]}"/>
                      </div>
                      <field name="carrier_price"/>
                    </group>
                </xpath>
            </field>
        </record>

    </data>
</openerp>

{'fraction_non_alphanumeric': 0.14085783595020393, 'fraction_numerical': 0.001279556420440914, 'mean_word_length': 1.3940012763241862, 'pattern_counts': {'":': 0, '<': 739, '<?xml version=': 0, '>': 739, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 22}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 52, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '907237', 'n_tokens_mistral': 9662, 'n_tokens_neox': 9150, 'n_words': 1668}