[FIX] product: price precision
- Set a decimal precision for 'Product Price' = 6 - Set a currency precision = 2 - In the product for view, set a 'Sales Price' = 0.123456 The price is rounded to 0.12, while one would expect it to be 0.123456. We use the decimal precision of the field rather than the default currency precision. Fixes #21686 opw-800279
This commit is contained in:
committed by
Nicolas Martinelli
parent
38e73da092
commit
cf32a23b92
@@ -47,10 +47,10 @@
|
||||
<field name="categ_id" string="Category"/>
|
||||
</group>
|
||||
<group name="group_standard_price">
|
||||
<field name="list_price" widget='monetary' options="{'currency_field': 'currency_id'}"/>
|
||||
<field name="list_price" widget='monetary' options="{'currency_field': 'currency_id', 'field_digits': True}"/>
|
||||
<label for="standard_price" groups="base.group_user" attrs="{'invisible': [('product_variant_count', '>', 1)]}"/>
|
||||
<div name="standard_price_uom" groups="base.group_user" attrs="{'invisible': [('product_variant_count', '>', 1)]}">
|
||||
<field name="standard_price" widget='monetary' options="{'currency_field': 'currency_id'}"/>
|
||||
<field name="standard_price" widget='monetary' options="{'currency_field': 'currency_id', 'field_digits': True}"/>
|
||||
</div>
|
||||
<field name="company_id" groups="base.group_multi_company"
|
||||
options="{'no_create': True}"/>
|
||||
@@ -213,8 +213,8 @@
|
||||
<group>
|
||||
<group name="pricing" string="Pricing">
|
||||
<field name="product_variant_count" invisible="1"/>
|
||||
<field name="lst_price" widget='monetary' options="{'currency_field': 'currency_id'}" attrs="{'readonly': [('product_variant_count', '>', 1)]}"/>
|
||||
<field name="standard_price" widget='monetary' options="{'currency_field': 'currency_id'}"/>
|
||||
<field name="lst_price" widget='monetary' options="{'currency_field': 'currency_id', 'field_digits': True}" attrs="{'readonly': [('product_variant_count', '>', 1)]}"/>
|
||||
<field name="standard_price" widget='monetary' options="{'currency_field': 'currency_id', 'field_digits': True}"/>
|
||||
<field name="currency_id" invisible='1'/>
|
||||
</group>
|
||||
<group name="weight">
|
||||
|
||||
Reference in New Issue
Block a user