[MERGE] merge with lp:~openerp-dev/openobject-addons/trunk-product-variant-imp-amb-dka
bzr revid: amb@tinyerp.com-20131015121142-hq7foz2jhrq2hi73
This commit is contained in:
@@ -31,12 +31,16 @@
|
||||
<field name="arch" type="xml">
|
||||
<notebook position="inside">
|
||||
<page string="Accounting">
|
||||
<separator string="Sales Properties" colspan="2"/>
|
||||
<separator string="Purchase Properties" colspan="2"/>
|
||||
<field name="property_account_income" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="property_account_expense" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="taxes_id"/>
|
||||
<field name="supplier_taxes_id"/>
|
||||
<group name="properties">
|
||||
<group>
|
||||
<field name="property_account_income" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="taxes_id" colspan="2" widget="many2many_tags"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="property_account_expense" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="supplier_taxes_id" colspan="2" widget="many2many_tags"/>
|
||||
</group>
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
</field>
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="account.product_template_form_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="/form/notebook/page/field[@name='property_account_expense']" position="after">
|
||||
<xpath expr="//field[@name='property_account_expense']" position="after">
|
||||
<field name="property_account_creditor_price_difference" domain="[('type','<>','view'),('type','<>','consolidation')]" attrs="{'readonly':[('purchase_ok','=',0)]}" />
|
||||
<newline/>
|
||||
</xpath>
|
||||
|
||||
@@ -291,15 +291,49 @@
|
||||
<field name="res_model">stock.warehouse.orderpoint</field>
|
||||
</record>
|
||||
|
||||
<record id="product_template_search_view_procurment" model="ir.ui.view">
|
||||
<field name="name">product.template.search.procurment</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="product.product_template_search_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<filter name="consumable" position="before">
|
||||
<filter string="Products" icon="terp-accessories-archiver" domain="[('type','=','product')]" help="Stockable products"/>
|
||||
</filter>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="product_template_form_view_procurement">
|
||||
<field name="name">product.template.procurement</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="product.product_template_form_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//field[@name='type']" position="after">
|
||||
<xpath expr="//field[@name='cost_method']" position="before">
|
||||
<field name="procure_method"/>
|
||||
<field name="supply_method"/>
|
||||
</xpath>
|
||||
<xpath expr="//group[@name='general']" position="after" >
|
||||
<group name="procurement_help" class="oe_grey" col="1" groups="base.group_user">
|
||||
<p attrs="{'invisible': ['|','|',('type','<>','service'),('procure_method','<>','make_to_stock')]}">
|
||||
When you sell this service, nothing special will be triggered
|
||||
to deliver the customer, as you set the procurement method as
|
||||
'Make to Stock'.
|
||||
</p>
|
||||
<p attrs="{'invisible': ['|','|',('type','<>','product'),('procure_method','<>','make_to_stock')]}">
|
||||
When you sell this product, OpenERP will <b>use the available
|
||||
inventory</b> for the delivery order.
|
||||
<br/><br/>
|
||||
If there are not enough quantities available, the delivery order
|
||||
will wait for new products. To fulfill the inventory, you should
|
||||
create others rules like orderpoints.
|
||||
</p>
|
||||
<p attrs="{'invisible': ['|','|',('type','<>','consu'),('procure_method','<>','make_to_stock')]}">
|
||||
When you sell this product, a delivery order will be created.
|
||||
OpenERP will consider that the <b>required quantities are always
|
||||
available</b> as it's a consumable (as a result of this, the quantity
|
||||
on hand may become negative).
|
||||
</p>
|
||||
</group>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
+126
-64
@@ -8,7 +8,7 @@
|
||||
<field name="model">product.product</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Product">
|
||||
<field name="name" string="Product" filter_domain="['|',('name','ilike',self),('default_code','ilike',self)]"/>
|
||||
<field name="name" string="Product" filter_domain="['|','|',('name','ilike',self),('default_code','ilike',self),('variants','ilike',self)]"/>
|
||||
<filter string="Services" icon="terp-accessories-archiver" domain="[('type','=','service')]"/>
|
||||
<filter string="Consumable" name="consumable" icon="terp-accessories-archiver" domain="[('type','=','consu')]" help="Consumable products"/>
|
||||
<separator/>
|
||||
@@ -23,6 +23,7 @@
|
||||
<filter string='Default Unit of Measure' icon="terp-mrp" domain="[]" context="{'group_by' : 'uom_id'}"/>
|
||||
<filter string='Type' icon="terp-stock_symbol-selection" domain="[]" context="{'group_by' : 'type'}"/>
|
||||
<filter string='Company' icon="terp-go-home" domain="[]" context="{'group_by' : 'company_id'}" groups="base.group_multi_company"/>
|
||||
<filter string='Template' name="template_id" domain="[]" context="{'group_by' : 'product_tmpl_id'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
@@ -36,6 +37,7 @@
|
||||
<tree colors="red:virtual_available<0;blue:virtual_available>=0 and state in ('draft', 'end', 'obsolete');black:virtual_available>=0 and state not in ('draft', 'end', 'obsolete')" string="Products">
|
||||
<field name="default_code"/>
|
||||
<field name="name"/>
|
||||
<field name="variants"/>
|
||||
<field name="categ_id" invisible="1"/>
|
||||
<field name="type" invisible="1"/>
|
||||
<field name="uom_id" string="Unit of Measure" groups="product.group_uom"/>
|
||||
@@ -46,6 +48,7 @@
|
||||
<field name="standard_price" invisible="1"/>
|
||||
<field name="state"/>
|
||||
<field name="company_id" groups="base.group_multi_company" invisible="1"/>
|
||||
<field name="product_tmpl_id" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
@@ -187,7 +190,7 @@
|
||||
<div class="oe_kanban_details">
|
||||
<h4>
|
||||
<a type="open">
|
||||
<t t-if="record.code.raw_value">[<field name="code"/>]</t> <field name="name"/>
|
||||
<t t-if="record.code.raw_value">[<field name="code"/>]</t> <field name="name"/> <t t-if="record.variants.raw_value">(<field name="variants"/>)</t>
|
||||
</a>
|
||||
</h4>
|
||||
<div name="tags"/>
|
||||
@@ -223,9 +226,9 @@
|
||||
<field name="name">Products</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">product.product</field>
|
||||
<field name="view_mode">kanban,tree,form</field>
|
||||
<field name="view_mode">tree,form,kanban</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="context">{"search_default_filter_to_sell":1}</field>
|
||||
<field name="context">{"search_default_template_id":1, "search_default_filter_to_sell":1}</field>
|
||||
<field name="view_id" ref="product_product_tree_view"/>
|
||||
<field name="search_view_id" ref="product_search_form_view"/>
|
||||
<field name="help" type="html">
|
||||
@@ -244,21 +247,21 @@
|
||||
</record>
|
||||
|
||||
<record id="open_view_product_tree1" model="ir.actions.act_window.view">
|
||||
<field name="sequence" eval="2"/>
|
||||
<field name="sequence" eval="1"/>
|
||||
<field name="view_mode">tree</field>
|
||||
<field name="view_id" ref="product_product_tree_view"/>
|
||||
<field name="act_window_id" ref="product_normal_action_sell"/>
|
||||
</record>
|
||||
|
||||
<record id="open_view_product_form1" model="ir.actions.act_window.view">
|
||||
<field name="sequence" eval="3"/>
|
||||
<field name="sequence" eval="2"/>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="view_id" ref="product_normal_form_view"/>
|
||||
<field name="act_window_id" ref="product_normal_action_sell"/>
|
||||
</record>
|
||||
|
||||
<record id="open_view_product_kanban1" model="ir.actions.act_window.view">
|
||||
<field name="sequence" eval="1"/>
|
||||
<field name="sequence" eval="3"/>
|
||||
<field name="view_mode">kanban</field>
|
||||
<field name="view_id" ref="product_kanban_view"/>
|
||||
<field name="act_window_id" ref="product_normal_action_sell"/>
|
||||
@@ -623,7 +626,10 @@
|
||||
<field name="active"/>
|
||||
<field name="variants" required="1"/>
|
||||
<field name="default_code"/>
|
||||
<field name="price_margin"/>
|
||||
<label for="price_margin"/>
|
||||
<div>
|
||||
<field name="price_margin" class="oe_inline" style="vertical-align:baseline"/> %%
|
||||
</div>
|
||||
<field name="price_extra"/>
|
||||
</group>
|
||||
</form>
|
||||
@@ -673,9 +679,30 @@
|
||||
<field name="view_id" ref="product_variant_form_view"/>
|
||||
<field name="act_window_id" ref="product_variant_action"/>
|
||||
</record>
|
||||
<menuitem action="product.product_variant_action" id="product.menu_variant_product" parent="base.menu_product" sequence="100" groups="product.group_product_variant"/>
|
||||
<menuitem action="product.product_variant_action" id="product.menu_variant_product" parent="prod_config_main" sequence="100" groups="product.group_product_variant"/>
|
||||
|
||||
<!-- templates -->
|
||||
|
||||
<record id="product_template_search_view" model="ir.ui.view">
|
||||
<field name="name">product.template.search</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Product Template">
|
||||
<field name="name" string="Product"/>
|
||||
<filter string="Services" icon="terp-accessories-archiver" domain="[('type','=','service')]"/>
|
||||
<filter string="Consumable" name="consumable" icon="terp-accessories-archiver" domain="[('type','=','consu')]" help="Consumable products"/>
|
||||
<separator/>
|
||||
<filter string="Can be Sold" name="filter_to_sell" icon="terp-accessories-archiver-minus" domain="[('sale_ok','=',1)]"/>
|
||||
<field name="categ_id"/>
|
||||
<group expand='0' string='Group by...'>
|
||||
<filter string='Category' icon="terp-stock_symbol-selection" domain="[]" context="{'group_by' : 'categ_id'}"/>
|
||||
<filter string='Default Unit of Measure' icon="terp-mrp" domain="[]" context="{'group_by' : 'uom_id'}"/>
|
||||
<filter string='Type' icon="terp-stock_symbol-selection" domain="[]" context="{'group_by' : 'type'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="product_template_tree_view" model="ir.ui.view">
|
||||
<field name="name">product.template.product.tree</field>
|
||||
<field name="model">product.template</field>
|
||||
@@ -685,6 +712,7 @@
|
||||
<field name="categ_id"/>
|
||||
<field name="type"/>
|
||||
<field name="state"/>
|
||||
<field name="uom_id" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
@@ -705,81 +733,80 @@
|
||||
</h1>
|
||||
<label for="categ_id" class="oe_edit_only"/>
|
||||
<h2><field name="categ_id"/></h2>
|
||||
<div name="options" groups="base.group_user">
|
||||
<field name="sale_ok"/>
|
||||
<label for="sale_ok"/>
|
||||
</div>
|
||||
</div>
|
||||
<notebook>
|
||||
<page string="Information">
|
||||
<group>
|
||||
<group string="Product Type">
|
||||
<field name="sale_ok"/>
|
||||
</group>
|
||||
<group string="Procurement">
|
||||
<field name="type"/>
|
||||
</group>
|
||||
|
||||
<group string="Base Prices">
|
||||
<group>
|
||||
<field name="type" class="oe_inline"/>
|
||||
<field name="uom_id" class="oe_inline" on_change="onchange_uom(uom_id,uom_po_id)" groups="product.group_uom"/>
|
||||
<field name="list_price"/>
|
||||
<field name="standard_price" attrs="{'readonly':[('cost_method','=','average')]}"/>
|
||||
<field name="cost_method"/>
|
||||
</group>
|
||||
|
||||
<group string="Weights">
|
||||
<field digits="(14, 3)" name="volume" attrs="{'readonly':[('type','=','service')]}"/>
|
||||
<field digits="(14, 3)" name="weight" attrs="{'readonly':[('type','=','service')]}"/>
|
||||
<field digits="(14, 3)" name="weight_net" attrs="{'readonly':[('type','=','service')]}"/>
|
||||
</group>
|
||||
|
||||
<group name="status" string="Status">
|
||||
<field name="categ_id"/>
|
||||
<field name="state"/>
|
||||
<field name="product_manager" context="{'default_groups_ref': ['base.group_user', 'base.group_partner_manager', 'base.group_sale_manager']}"/>
|
||||
</group>
|
||||
|
||||
<group name="uom" string="Unit of Measure">
|
||||
<field name="uom_id" on_change="onchange_uom(uom_id,uom_po_id)" groups="product.group_uom"/>
|
||||
<field name="uom_po_id"/>
|
||||
</group>
|
||||
|
||||
<group name="uos" groups="product.group_uom" string="Second Unit of Measure">
|
||||
<field name="uos_id"/>
|
||||
<field name="uos_coeff"/>
|
||||
<field name="mes_type"/>
|
||||
</group>
|
||||
|
||||
<group colspan="4" string="Product Variants">
|
||||
<field colspan="4" name="product_variant_ids" nolabel="1">
|
||||
<tree string="Product Variants" editable="bottom">
|
||||
<field name="active"/>
|
||||
<field name="variants" required="1"/>
|
||||
<field name="default_code"/>
|
||||
<field name="price_margin"/>
|
||||
<field name="price_margin" string="Variant Price Margin(%%)"/>
|
||||
<field name="price_extra"/>
|
||||
<field name="lst_price" string="Sale Price"/>
|
||||
</tree>
|
||||
</field>
|
||||
</group>
|
||||
</group>
|
||||
<field name="description" placeholder="describe the product characteristics..."/>
|
||||
</page>
|
||||
<page string="Procurement & Locations">
|
||||
<group>
|
||||
<page string="Procurements" groups="base.group_user">
|
||||
<group name="procurement">
|
||||
<group name="general">
|
||||
<field name="cost_method" groups="product.group_costing_method"/>
|
||||
<field name="standard_price" attrs="{'readonly':[('cost_method','=','average')]}"/>
|
||||
</group>
|
||||
<group name="delay" string="Delays">
|
||||
<label for="produce_delay"/>
|
||||
<div>
|
||||
<field name="produce_delay" class="oe_inline"/> days
|
||||
<field name="produce_delay" class="oe_inline" style="vertical-align:baseline"/> days
|
||||
</div>
|
||||
<field name="warranty"/>
|
||||
</group>
|
||||
<group name="procurement_uom" groups="product.group_uom" string="Purchase">
|
||||
<field name="uom_po_id"/>
|
||||
</group>
|
||||
</group>
|
||||
|
||||
</page>
|
||||
<page string="Suppliers">
|
||||
<separator string="Suppliers"/>
|
||||
<field name="seller_ids"/>
|
||||
<separator string="Description for Suppliers"/>
|
||||
<field name="description_purchase" placeholder="This note will be displayed on requests for quotation..."/>
|
||||
</page>
|
||||
<page string="Descriptions">
|
||||
<separator string="Internal Description"/>
|
||||
<field name="description"/>
|
||||
<separator string="Sale Description"/>
|
||||
<field name="description_sale"/>
|
||||
<separator string="Purchase Description"/>
|
||||
<field name="description_purchase"/>
|
||||
<page string="Inventory">
|
||||
<group name="inventory">
|
||||
<group name="status" string="Status">
|
||||
<field name="state"/>
|
||||
<field name="product_manager"/>
|
||||
</group>
|
||||
<group string="Weights">
|
||||
<field digits="(14, 3)" name="volume" attrs="{'readonly':[('type','=','service')]}"/>
|
||||
<field digits="(14, 3)" name="weight" attrs="{'readonly':[('type','=','service')]}"/>
|
||||
<field digits="(14, 3)" name="weight_net" attrs="{'readonly':[('type','=','service')]}"/>
|
||||
</group>
|
||||
</group>
|
||||
</page>
|
||||
<page string="Sales" attrs="{'invisible':[('sale_ok','=',False)]}">
|
||||
<group name="sale">
|
||||
<group string="Sale Conditions">
|
||||
<label for="warranty"/>
|
||||
<div>
|
||||
<field name="warranty" class="oe_inline" style="vertical-align:baseline"/> months
|
||||
</div>
|
||||
</group>
|
||||
<group groups="product.group_uos" string="Unit of Measure">
|
||||
<field name="uos_id"/>
|
||||
<field name="uos_coeff"/>
|
||||
<field name="mes_type"/>
|
||||
</group>
|
||||
</group>
|
||||
<separator string="Description for Quotations"/>
|
||||
<field name="description_sale" placeholder="note to be displayed on quotations..."/>
|
||||
</page>
|
||||
</notebook>
|
||||
</sheet>
|
||||
@@ -787,13 +814,48 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="product_template_action_tree" model="ir.actions.act_window">
|
||||
<record model="ir.ui.view" id="product_template_kanban_view">
|
||||
<field name="name">Product Template Kanban</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="arch" type="xml">
|
||||
<kanban>
|
||||
<field name="image_small"/>
|
||||
<field name="list_price"/>
|
||||
<templates>
|
||||
<t t-name="kanban-box">
|
||||
<div class="oe_kanban_vignette oe_semantic_html_override">
|
||||
<a type="open"><img t-att-src="kanban_image('product.product', 'image_small', record.id.value)" class="oe_kanban_image"/></a>
|
||||
<div class="oe_kanban_details">
|
||||
<h4>
|
||||
<a type="open">
|
||||
<field name="name"/>
|
||||
</a>
|
||||
</h4>
|
||||
<div name="tags"/>
|
||||
<ul>
|
||||
<li>Price: <field name="list_price"></field></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</t>
|
||||
</templates>
|
||||
</kanban>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="product_template_action" model="ir.actions.act_window">
|
||||
<field name="name">Product Templates</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">product.template</field>
|
||||
<field name="view_mode">kanban,tree,form</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="product_template_tree_view"/>
|
||||
<field name="view_id" ref="product_template_kanban_view"/>
|
||||
</record>
|
||||
|
||||
<menuitem action="product_template_action"
|
||||
groups="product.group_product_variant"
|
||||
id="menu_product_template_action"
|
||||
parent="prod_config_main" sequence="3"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -594,14 +594,26 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="product_template_search_view_purchase" model="ir.ui.view">
|
||||
<field name="name">product.template.search.purchase</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="product.product_template_search_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<filter name="filter_to_sell" position="after">
|
||||
<filter name="filter_to_purchase" string="Can be Purchased" icon="terp-accessories-archiver+" domain="[('purchase_ok', '=', 1)]"/>
|
||||
</filter>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_template_purchase_ok_form" model="ir.ui.view">
|
||||
<field name="name">product.template.purchase.ok.form.inherit</field>
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="product.product_template_form_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="sale_ok" position="after">
|
||||
<div name="options" position="inside">
|
||||
<field name="purchase_ok"/>
|
||||
</field>
|
||||
<label for="purchase_ok"/>
|
||||
</div>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.actions.act_window" id="action_purchase_line_product_tree">
|
||||
|
||||
@@ -37,29 +37,30 @@
|
||||
<field name="model">product.template</field>
|
||||
<field name="inherit_id" ref="product.product_template_form_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<group name="delay" position="inside">
|
||||
<field name="sale_delay" attrs="{'readonly':[('sale_ok','=',False)]}"/>
|
||||
</group>
|
||||
<group name="delay" position="after">
|
||||
<group name="store" string="Storage Location">
|
||||
<xpath expr="//group[@string='Sale Conditions']" position="inside">
|
||||
<label for="sale_delay"/>
|
||||
<div>
|
||||
<field name="sale_delay" attrs="{'readonly':[('sale_ok','=',False)]}" class="oe_inline" style="vertical-align:baseline"/> days
|
||||
</div>
|
||||
</xpath>
|
||||
<xpath expr="//group[@name='status']" position="after">
|
||||
<group name="store" string="Storage Location">
|
||||
<field name="loc_rack"/>
|
||||
<field name="loc_row"/>
|
||||
<field name="loc_case"/>
|
||||
</group>
|
||||
</group>
|
||||
<page position="after" string="Information">
|
||||
<page string="Properties">
|
||||
<group string="Counter-Part Locations Properties" groups="stock.group_locations">
|
||||
<field name="property_stock_procurement" domain="[('usage','=','procurement')]"/>
|
||||
<field name="property_stock_production" domain="[('usage','=','production')]"/>
|
||||
<field name="property_stock_inventory" domain="[('usage','=','inventory')]"/>
|
||||
</group>
|
||||
<group string="Accounting Entries">
|
||||
<field name="property_stock_account_input" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="property_stock_account_output" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
</group>
|
||||
</page>
|
||||
</page>
|
||||
<field name="loc_case"/>
|
||||
</group>
|
||||
</xpath>
|
||||
<xpath expr="//group[@string='Weights']" position="after">
|
||||
<group string="Accounting Entries">
|
||||
<field name="property_stock_account_input" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="property_stock_account_output" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
</group>
|
||||
<group string="Counter-Part Locations Properties" groups="stock.group_locations">
|
||||
<field name="property_stock_procurement" domain="[('usage','=','procurement')]"/>
|
||||
<field name="property_stock_production" domain="[('usage','=','production')]"/>
|
||||
<field name="property_stock_inventory" domain="[('usage','=','inventory')]"/>
|
||||
</group>
|
||||
</xpath>
|
||||
<field name="product_manager" position="attributes" version="7.0">
|
||||
<attribute name="context">{'default_groups_ref': ['base.group_user', 'base.group_sale_manager', 'stock.group_stock_manager']}</attribute>
|
||||
</field>
|
||||
|
||||
Reference in New Issue
Block a user