Skip to Content
Menu
This question has been flagged
5 Replies
16183 Views

Hello there,

I would like to ask you guys for some additional help. We are encountering a little problem with the decimals. When we sell our products the prices may show 2 decimals so that's correct and should stay that way. 

But when purchase any products from a vendor the prices needs to be filled in with 4 or 5 decimals without using any rounding method. Now if I buy multiple products from our vendor the prices are rounded, I would like to give fill in prices "only within the purchase tab in the product form" with as many decimals as I want. 

We use "for now" the online Odoo version this will soon be the Odoo Estate version. Can I change this with XPath customization or are there some hidden configuration settings for each specific field? 


Additional information:

Relation: product.supplierinfo

Field: seller_ids

Type of field: float

Object: product.template

Update:

I created a new decimal precision (purchase prices) with 4 decimals in the technical settings. Can I just assign that new precision to any field? If yes, how can I do that? 

Thanks already for your help. 

Kinds regards,

Gerwin






Avatar
Discard
Best Answer

There is a configuration to increase / decrease the decimal precision. In your case, you need to change the value for "Product Price".

You can find this configuration in "Technical / Database Structure / Decimal Accuracy" and then search for record for "Product Price" and change the value of "Digits" field.

Avatar
Discard
Author

Thanks for your support. This I tried already, but then the prices of the products will be in 4 digits also. I only want the vendor purchase price to be 4 digits. Otherwise, the price's that I will sell for won't match. Do you get what I mean? I'm now trying to edit the Xpath in Odoo Studio XML editor and add this: digits="get_precision('Purchase prices')" but that didn't work also :S

Some suggestions?

I think you will need little customization. In the custom module, you will have to overwrite the field and then change the digits as per your need.

Author

I got the following fields in the: Odoo Studio: product.template.product.form customization

<tree string="Vendor Information">

<field name="sequence" widget="handle"/>

<field name="name"/>

<field name="product_id" invisible="context.get('product_template_invisible_variant', False)" groups="product.group_product_variant"/>

<field name="product_tmpl_id" string="Product" invisible="context.get('visible_product_tmpl_id', True)"/>

<field name="min_qty"/>

<field name="product_uom" groups="uom.group_uom"/>

<field name="price" target="Price" string="Inkoop prijs" widget="monetary" digits="get_precision('Purchase prices')"/>

<field name="currency_id" groups="base.group_multi_currency"/>

<field name="date_start"/>

<field name="date_end"/>

</tree>

Can I make the little customization in here? Or somewhere else?

Thanks again for your response.

Best Answer

Hey Gerwin! Did you ever solve this issue? If yes, could you share please. 

Thanx

Avatar
Discard
Related Posts Replies Views Activity
0
Apr 25
74
5
Aug 24
1294
0
Jan 22
1545
1
Mar 25
3496
1
Sep 21
5071