Add quantity fields in template and product form view

This commit is contained in:
Jordi Esteve 2015-07-01 21:39:22 +02:00
parent 9f57d1f288
commit 15bd2bf2dc
3 changed files with 38 additions and 0 deletions

View File

@ -9,6 +9,12 @@ The COPYRIGHT file at the top level of this repository contains the full copyrig
<field name="type">tree</field>
<field name="name">template_qty_tree</field>
</record>
<record model="ir.ui.view" id="template_qty_view_form">
<field name="model">product.template</field>
<field name="inherit" ref="product.template_view_form"/>
<field name="type">form</field>
<field name="name">template_qty_form</field>
</record>
<record model="ir.action.act_window" id="act_template_qty_form">
<field name="name">Qty Products</field>
@ -38,6 +44,12 @@ The COPYRIGHT file at the top level of this repository contains the full copyrig
<field name="type">tree</field>
<field name="name">product_qty_tree</field>
</record>
<record model="ir.ui.view" id="product_qty_view_form">
<field name="model">product.product</field>
<field name="inherit" ref="product.product_view_form"/>
<field name="type">form</field>
<field name="name">product_qty_form</field>
</record>
<record model="ir.action.act_window" id="act_product_qty_form">
<field name="name">Qty Variants</field>
@ -84,6 +96,7 @@ The COPYRIGHT file at the top level of this repository contains the full copyrig
<record model="ir.ui.view" id="template_qty_manufacturer_view_tree">
<field name="model">product.template</field>
<field name="inherit" ref="template_qty_view_tree"/>
<field name="type">tree</field>
<field name="name">template_qty_manufacturer_tree</field>
</record>
</data>
@ -92,6 +105,7 @@ The COPYRIGHT file at the top level of this repository contains the full copyrig
<record model="ir.ui.view" id="template_qty_purchase_view_tree">
<field name="model">product.template</field>
<field name="inherit" ref="template_qty_view_tree"/>
<field name="type">tree</field>
<field name="name">template_qty_purchase_tree</field>
</record>
</data>

12
view/product_qty_form.xml Normal file
View File

@ -0,0 +1,12 @@
<?xml version="1.0"?>
<!-- This file is part of product_kit module for Tryton.
The COPYRIGHT file at the top level of this repository contains the full copyright notices and license terms. -->
<data>
<xpath expr="/form/field[@name='description']"
position="after">
<label name="quantity"/>
<field name="quantity"/>
<label name="forecast_quantity"/>
<field name="forecast_quantity"/>
</xpath>
</data>

View File

@ -0,0 +1,12 @@
<?xml version="1.0"?>
<!-- The COPYRIGHT file at the top level of this repository contains the full
copyright notices and license terms. -->
<data>
<xpath expr="/form/notebook/page[@id='general']/field[@name='cost_price_method']"
position="after">
<label name="quantity"/>
<field name="quantity"/>
<label name="forecast_quantity"/>
<field name="forecast_quantity"/>
</xpath>
</data>