[FIX] sale: set B2B as default mode at installation
Before this fix, you was in an 'unknow' mode before to have selected the mode
in the sale res config after the install of sale.
Side effect:
Empty value in ecommerce
Missing column subtotal in 'sale.order' and related report
Now, with fix, mode B2B is set by default (was the only mode in old version)
Using same behavior that the method execute of class resConfigSetting.
Usability: set the default option as the first choice in the res config.
This commit is contained in:
@@ -72,8 +72,8 @@ class sale_configuration(osv.TransientModel):
|
||||
'group_show_price_subtotal': fields.boolean("Show subtotal", implied_group='sale.group_show_price_subtotal', group='base.group_portal,base.group_user,base.group_public'),
|
||||
'group_show_price_total': fields.boolean("Show total", implied_group='sale.group_show_price_total', group='base.group_portal,base.group_user,base.group_public'),
|
||||
'sale_show_tax': fields.selection([
|
||||
('total', 'Show line subtotals with taxes included (B2C)'),
|
||||
('subtotal', 'Show line subtotals without taxes (except if unit price includes taxes) (B2B)')], "Tax Display",
|
||||
('subtotal', 'Show line subtotals without taxes (B2B)'),
|
||||
('total', 'Show line subtotals with taxes included (B2C)')], "Tax Display",
|
||||
required=True),
|
||||
'default_invoice_policy': fields.selection([
|
||||
('order', 'Invoice ordered quantities'),
|
||||
|
||||
@@ -25,6 +25,18 @@
|
||||
<field name="comment">Show line subtotals with taxes included (B2C)</field>
|
||||
</record>
|
||||
|
||||
<record model="res.groups" id="base.group_public">
|
||||
<field name="implied_ids" eval="[(4, ref('sale.group_show_price_subtotal'))]"/>
|
||||
</record>
|
||||
|
||||
<record model="res.groups" id="base.group_portal">
|
||||
<field name="implied_ids" eval="[(4, ref('sale.group_show_price_subtotal'))]"/>
|
||||
</record>
|
||||
|
||||
<record model="res.groups" id="base.group_user">
|
||||
<field name="implied_ids" eval="[(4, ref('sale.group_show_price_subtotal'))]"/>
|
||||
</record>
|
||||
|
||||
<record id="group_mrp_properties" model="res.groups">
|
||||
<field name="name">Properties on lines</field>
|
||||
<field name="category_id" ref="base.module_category_hidden"/>
|
||||
|
||||
Reference in New Issue
Block a user