[IMP] product: rename xml ids of new usability groups

bzr revid: rco@openerp.com-20120321100144-h5f6jjuz45p2qi6r
This commit is contained in:
Raphael Collet 2012-03-21 11:01:44 +01:00
parent 96169ebeb3
commit ff05f5dd8f
13 changed files with 46 additions and 57 deletions

View File

@ -11,7 +11,7 @@
<group colspan="2" col="2" name="invoice_data">
<separator colspan="2" string="Invoicing Data"/>
<field name="to_invoice" widget="selection"/>
<field name="pricelist_id" groups="base.group_sale_pricelist_per_customer" domain="[('type','=','sale')]" attrs="{'required':[('to_invoice','!=',False)]}"/>
<field name="pricelist_id" groups="product.group_sale_pricelist" domain="[('type','=','sale')]" attrs="{'required':[('to_invoice','!=',False)]}"/>
<field name="amount_max"/>
</group>
<group colspan="2" col="2" name="invoice_stats">

View File

@ -118,7 +118,7 @@
<page string="Invoicing">
<field name="invoice_method" colspan="4"/>
<field
name="pricelist_id" groups="base.group_sale_pricelist_per_customer" context="{'product_id':product_id}"
name="pricelist_id" groups="product.group_sale_pricelist" context="{'product_id':product_id}"
attrs="{'readonly':[('invoice_method','=', 'none')]}"/>
<field name="partner_invoice_id" attrs="{'readonly':[('invoice_method','=', 'none')]}"/>
<!-- <field name="invoice_id"/> -->

View File

@ -80,7 +80,7 @@
<field name="company_id" groups="base.group_multi_company"/>
<field name="shop_id" widget="selection"/>
<field name="user_id"/>
<field name="pricelist_id" groups="base.group_sale_pricelist_per_customer" domain="[('type','=','sale')]"/>
<field name="pricelist_id" groups="product.group_sale_pricelist" domain="[('type','=','sale')]"/>
<field name="picking_id" readonly="1" groups="base.group_extended"/>
</group>
<group colspan="2" col="3">

View File

@ -9,7 +9,7 @@
<field name="arch" type="xml">
<page string="Sales &amp; Purchases" position="inside">
<newline/>
<group col="2" colspan="2" groups="base.group_sale_pricelist_per_customer">
<group col="2" colspan="2" groups="product.group_sale_pricelist">
<separator string="Sales Properties" colspan="2"/>
<field name="property_product_pricelist"/>
</group>

View File

@ -5,7 +5,7 @@
<menuitem id="base.menu_sale_config_sales" name="Sales"
parent="base.menu_base_config" sequence="0" groups="base.group_extended"/>
<menuitem id="menu_product_pricelist_main" name="Pricelists"
parent="base.menu_base_config" groups="base.group_sale_pricelist_per_customer" sequence="50"/>
parent="base.menu_base_config" groups="product.group_sale_pricelist" sequence="50"/>
<record id="product_pricelist_version_form_view" model="ir.ui.view">
<field name="name">product.pricelist.version.form</field>

View File

@ -20,7 +20,7 @@
<field name="categ_id" widget="selection" operator="child_of" groups="base.group_extended"/>
<newline/>
<group expand="0" string="Context..." groups="base.group_extended">
<field name="pricelist_id" widget="selection" context="{'pricelist': self}" groups="base.group_sale_pricelist_per_customer"/>
<field name="pricelist_id" widget="selection" context="{'pricelist': self}" groups="product.group_sale_pricelist"/>
<separator orientation="vertical" groups="base.group_multi_company" />
<field name="company_id" widget="selection" groups="base.group_multi_company" />
</group>
@ -50,7 +50,7 @@
<field name="name"/>
<field name="categ_id" invisible="1"/>
<field name="variants" groups="product.group_product_variant"/>
<field name="uom_id" string="UoM" groups="base.group_sale_uom_per_product"/>
<field name="uom_id" string="UoM" groups="product.group_uom"/>
<field name="type"/>
<field name="qty_available"/>
<field name="virtual_available"/>
@ -125,11 +125,11 @@
<group colspan="2" col="2" name="uom">
<separator string="Unit of Measure" colspan="2"/>
<field name="uom_id" on_change="onchange_uom(uom_id,uom_po_id)" groups="base.group_sale_uom_per_product"/>
<field name="uom_id" on_change="onchange_uom(uom_id,uom_po_id)" groups="product.group_uom"/>
<field name="uom_po_id" groups="base.group_extended"/>
</group>
<group colspan="2" col="2" name="uos" groups="base.group_sale_uom_per_product">
<group colspan="2" col="2" name="uos" groups="product.group_uom">
<separator string="Second UoM" colspan="2"/>
<field name="uos_id"/>
<field name="uos_coeff"/>
@ -440,7 +440,7 @@
<field name="view_id" ref="product_uom_tree_view"/>
<field name="help">Create and manage the units of measure you want to be used in your system. You can define a conversion rate between several Units of Measure within the same category.</field>
</record>
<menuitem id="next_id_16" name="Units of Measure" parent="prod_config_main" sequence="65" groups="base.group_sale_uom_per_product"/>
<menuitem id="next_id_16" name="Units of Measure" parent="prod_config_main" sequence="65" groups="product.group_uom"/>
<menuitem action="product_uom_form_action" id="menu_product_uom_form_action" parent="next_id_16"/>
<record id="product_uom_categ_form_view" model="ir.ui.view">
@ -552,7 +552,7 @@
<field name="product_uom"/>
<field name="delay"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field colspan="4" groups="base.group_sale_pricelist_per_customer" name="pricelist_ids" nolabel="1" widget="one2many_list">
<field colspan="4" groups="product.group_sale_pricelist" name="pricelist_ids" nolabel="1" widget="one2many_list">
<tree editable="bottom" string="Pricelist">
<field name="min_quantity"/>
<field name="price"/>
@ -674,11 +674,11 @@
<group colspan="2" col="2" name="uom">
<separator string="UOM" colspan="2"/>
<field name="uom_id" on_change="onchange_uom(uom_id,uom_po_id)" groups="base.group_sale_uom_per_product"/>
<field name="uom_id" on_change="onchange_uom(uom_id,uom_po_id)" groups="product.group_uom"/>
<field name="uom_po_id" groups="base.group_extended"/>
</group>
<group colspan="2" col="2" name="uos" groups="base.group_sale_uom_per_product">
<group colspan="2" col="2" name="uos" groups="product.group_uom">
<separator string="Second UoM" colspan="2"/>
<field name="uos_id"/>
<field name="uos_coeff"/>

View File

@ -25,22 +25,18 @@ class sale_config_settings(osv.osv_memory):
_inherit = 'sale.config.settings'
_columns = {
'group_sale_pricelist_per_customer':fields.boolean("Pricelist per Customer",
group='base.group_user', implied_group='base.group_sale_pricelist_per_customer',
help="""Allows to manage different prices based on rules per category of customers.
Example: 10% for retailers, promotion of 5 EUR on this product, etc.
It assigns the "Pricelist" group to all employees."""),
'group_sale_uom_per_product':fields.boolean("UOM per product",
group='base.group_user', implied_group='base.group_sale_uom_per_product',
help="""
Allows you to select and maintain different unit of measures per product.
It assigns the "UOM per product" group to all employees.
"""),
'group_purchase_pricelist_per_supplier':fields.boolean("Pricelist per Supplier", group='base.group_user', xml_id='base.group_purchase_pricelist_per_supplier',
help="""Allows to manage different prices based on rules per category of Supplier.
Example: 10% for retailers, promotion of 5 EUR on this product, etc.
It assigns the "Pricelist" group to all employees."""),
'group_stock_packaging':fields.boolean("Manage packaging by products", group='base.group_user', implied_group='base.group_stock_packaging',
help=""" Allows you to create and manage your packaging dimensions and types you want to be maintained in your system.
It assigns the "Packaging" group to employee."""),
'group_sale_pricelist':fields.boolean("Pricelist per Customer",
implied_group='product.group_sale_pricelist',
help="""Allows to manage different prices based on rules per category of customers.
Example: 10% for retailers, promotion of 5 EUR on this product, etc."""),
'group_purchase_pricelist':fields.boolean("Pricelist per Supplier",
implied_group='product.group_purchase_pricelist',
help="""Allows to manage different prices based on rules per category of Supplier.
Example: 10% for retailers, promotion of 5 EUR on this product, etc."""),
'group_sale_uom':fields.boolean("UOM per product",
implied_group='product.group_uom',
help="""Allows you to select and maintain different unit of measures per product."""),
'group_stock_packaging':fields.boolean("Manage packaging by products",
implied_group='product.group_packaging',
help=""" Allows you to create and manage your packaging dimensions and types you want to be maintained in your system."""),
}

View File

@ -19,33 +19,26 @@
<field name="category_id" ref="base.module_category_usability"/>
</record>
<record id="base.group_sale_pricelist_per_customer" model="res.groups">
<record id="group_sale_pricelist" model="res.groups">
<field name="name">Sales Pricelists</field>
<field name="category_id" ref="base.module_category_hidden"/>
</record>
<record id="base.group_purchase_pricelist_per_supplier" model="res.groups">
<record id="group_purchase_pricelist" model="res.groups">
<field name="name">Purchase Pricelists</field>
<field name="category_id" ref="base.module_category_hidden"/>
</record>
<record id="base.group_sale_uom_per_product" model="res.groups">
<field name="name">Product UOM</field>
<record id="group_uom" model="res.groups">
<field name="name">Multiple UoM per Product</field>
<field name="category_id" ref="base.module_category_hidden"/>
</record>
<record id="base.group_stock_packaging" model="res.groups">
<field name="name">Packaging</field>
<record id="group_packaging" model="res.groups">
<field name="name">Manage Product Packaging</field>
<field name="category_id" ref="base.module_category_hidden"/>
</record>
<record id="base.group_user" model="res.groups">
<field name="implied_ids" eval="[(6,0,[ref('base.group_sale_pricelist_per_customer'),
ref('base.group_sale_uom_per_product'),
ref('base.group_purchase_pricelist_per_supplier'),
ref('base.group_stock_packaging')])]"/>
</record>
<record model="ir.rule" id="product_pricelist_comp_rule">
<field name="name">product pricelist company rule</field>
<field name="model_id" ref="model_product_pricelist"/>

View File

@ -31,7 +31,7 @@
name="Price List"
res_model="product.price_list"
src_model="product.product"
groups="base.group_sale_pricelist_per_customer"
groups="product.group_sale_pricelist"
view_mode="form" target="new" view_type="form" />
</data>

View File

@ -10,7 +10,7 @@
<field name="warn_customer" position="after">
<group colspan="4" col="4">
<separator colspan="4" string="Invoicing Data"/>
<field name="pricelist_id" groups="base.group_sale_pricelist_per_customer" domain="[('type','=','sale')]" widget="selection"/>
<field name="pricelist_id" groups="product.group_sale_pricelist" domain="[('type','=','sale')]" widget="selection"/>
<field name="to_invoice" widget="selection" string="Invoice Task Work"/>
<field name="amount_max" groups="base.group_extended"/>
<field name="amount_invoiced" groups="base.group_extended"/>

View File

@ -28,7 +28,7 @@
</group>
<separator string="Sale Order" colspan="4"/>
<group colspan="2" col="2">
<field name="group_sale_pricelist_per_customer"/>
<field name="group_sale_pricelist"/>
<field name="tax_policy" on_change="onchange_tax_policy(tax_policy)"/>
<field name="group_sale_taxes_global_on_order" invisible="1"/>
<field name="group_sale_taxes_on_order_line" invisible="1"/>
@ -36,7 +36,7 @@
<field name="module_warning"/>
</group>
<group colspan="2" col="2">
<field name="group_sale_uom_per_product"/>
<field name="group_sale_uom"/>
<field name="group_sale_delivery_address"/>
<field name="group_sale_disc_per_sale_order_line"/>
<field name="module_sale_layout"/>

View File

@ -21,7 +21,7 @@
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<separator colspan="4" string="Accounting"/>
<field name="payment_default_id"/>
<field domain="[('type','=','sale')]" name="pricelist_id" groups="base.group_sale_pricelist_per_customer" select="1"/>
<field domain="[('type','=','sale')]" name="pricelist_id" groups="product.group_sale_pricelist" select="1"/>
<field name="project_id" select="1" groups="analytic.group_analytic_accounting"/>
</form>
</field>
@ -34,7 +34,7 @@
<tree string="Sales Shop">
<field name="name"/>
<field name="warehouse_id"/>
<field name="pricelist_id" groups="base.group_sale_pricelist_per_customer"/>
<field name="pricelist_id" groups="product.group_sale_pricelist"/>
<field name="project_id" groups="analytic.group_analytic_accounting"/>
</tree>
</field>
@ -119,7 +119,7 @@
<field domain="[('partner_id','=',partner_id)]" name="partner_order_id" on_change="onchange_partner_order_id(partner_order_id, partner_invoice_id, partner_shipping_id)" options='{"quick_create": false}'/>
<field domain="[('partner_id','=',partner_id)]" name="partner_invoice_id" groups="base.group_sale_delivery_address" options='{"quick_create": false}'/>
<field domain="[('partner_id','=',partner_id)]" name="partner_shipping_id" groups="base.group_sale_delivery_address" options='{"quick_create": false}'/>
<field domain="[('type','=','sale')]" name="pricelist_id" groups="base.group_sale_pricelist_per_customer" on_change="onchange_pricelist_id(pricelist_id,order_line)"/>
<field domain="[('type','=','sale')]" name="pricelist_id" groups="product.group_sale_pricelist" on_change="onchange_pricelist_id(pricelist_id,order_line)"/>
<field name="project_id" context="{'partner_id':partner_id, 'contact_id':partner_order_id, 'pricelist_id':pricelist_id, 'default_name':name}" groups="analytic.group_analytic_accounting" domain="[('parent_id','!=',False)]"/>
<newline/>
<field colspan="4" name="order_line" nolabel="1" widget="one2many_list">
@ -139,7 +139,7 @@
on_change="product_id_change(parent.pricelist_id,product_id,product_uom_qty,product_uom,product_uos_qty,product_uos,name,parent.partner_id, False, False, parent.date_order, product_packaging, parent.fiscal_position, True, context)"/>
<field name="product_uom"
on_change="product_uom_change(parent.pricelist_id,product_id,product_uom_qty,product_uom,product_uos_qty,product_uos,name,parent.partner_id, False, False, parent.date_order, context)"
nolabel="1" groups="base.group_sale_uom_per_product"/>
nolabel="1" groups="product.group_uom"/>
<field name="price_unit"/>
<field groups="product.group_uos" name="product_uos_qty"/>
@ -184,7 +184,7 @@
<tree string="Sales Order Lines">
<field colspan="4" name="name"/>
<field name="product_uom_qty" string="Qty(UoM)"/>
<field name="product_uom" string="UoM" groups="base.group_sale_uom_per_product"/>
<field name="product_uom" string="UoM" groups="product.group_uom"/>
<field groups="product.group_uos" name="product_uos_qty" string="Qty(UoS)"/>
<field groups="product.group_uos" name="product_uos" string="UoS"/>
<field name="discount" groups="base.group_sale_disc_per_sale_order_line"/>
@ -363,7 +363,7 @@
<field name="order_partner_id"/>
<field name="product_id"/>
<field name="product_uom_qty" string="Qty"/>
<field name="product_uom" string="UoM" groups="base.group_sale_uom_per_product"/>
<field name="product_uom" string="UoM" groups="product.group_uom"/>
<field name="salesman_id"/>
<field name="price_subtotal" sum="Total" groups="base.group_sale_notes_subtotal"/>
<field name="state"/>
@ -384,7 +384,7 @@
<field name="product_id" readonly="1"/>
<field name="product_uom_qty" readonly="1"/>
<field name="product_uom" groups="base.group_sale_uom_per_product"/>
<field name="product_uom" groups="product.group_uom"/>
<field colspan="4" name="name" groups="base.group_extended"/>
<field name="company_id" groups="base.group_multi_company" readonly="1"/>

View File

@ -37,7 +37,7 @@
on_change="product_id_change(parent.pricelist_id,product_id,product_uom_qty,product_uom,product_uos_qty,product_uos,name,parent.partner_id, False, False, parent.date_order, product_packaging, parent.fiscal_position, True, context)"/>
<field name="product_uom"
nolabel="1"
groups="base.group_sale_uom_per_product"
groups="product.group_uom"
required="0"
attrs="{'invisible':[('layout_type','!=','article')], 'required':[('layout_type','not in',['title','text','subtotal','line','break'])]}"
on_change="product_uom_change(parent.pricelist_id,product_id,product_uom_qty,product_uom,product_uos_qty,product_uos,name,parent.partner_id, False, False, parent.date_order, context)"/>
@ -100,7 +100,7 @@
<tree string="Sales order lines">
<field colspan="4" name="name"/>
<field name="product_uom_qty" string="Qty"/>
<field name="product_uom" string="UoM" groups="base.group_sale_uom_per_product"/>
<field name="product_uom" string="UoM" groups="product.group_uom"/>
<field name="discount"/>
<field name="price_unit"/>
<!-- field name="price_net"/-->