Controlling the decimal precision is somewhat very tricky in OpenERP. As an example I want to wipe out the decimal number from all (pricelist, unit price, UoM, UoS, subtotal, tax, etc).
After I adjust it in the Settings --> Database Structure --> Decimal Accuracy (Product Price, Discount, Account, Product Unit of Measure, Product UoS) to become 0 digit, I found that in the Quotation, Sales Order, and Invoice form the "Untaxed Amount", "Taxes", and "Total" still displaying 2 digit decimal precision.
If I print the Quotation or Sales Order, I got the "Quantity" having 2 decimal digit, while "Untaxed Amount", "Taxes", and "Total" and the others don't have decimal digit.
If I print the Invoice I found that the "Quantity" and "Unit Price" have 2 decimal digit, but "Untaxed Amount", "Taxes", and "Total" and the others don't have any decimal digit.
How to make them consistence accross all the form and the printed version ?
I find the same problem. If I put in 6 digits for the Product Price in Settings/Database Structure/Decimal Accuracy, I can see that there are 6 digits in the product's sale price and purchase price, but when I actually use that product in an Expense report line, it shows 6 digits but rounds to 2 digits.
From the file hr_expense.py file, we see this line:
'unit_amount': fields.float('Unit Price', digits_compute=dp.get_precision('Product Price')),
so it looks like this is really where the precision setting is coming from. But where is the rounding coming from?
It appears the rounding comes from two locations: 1) Settings/Miscellaneous/Currencies. When I choose USD and edit the rounding to 0.000001 (instead of the original 0.010000), I get an error message saying that it can't be more precise than the "Account" setting.
2) So going to Settings/Database Configuration/Decimal Accuracy I find the Account item and change it to 6 digits. Then I can save the USD rounding to 0.000001. But the problem is that I want the pricing to be accurate to 6 decimal digits, but when an invoice is finally created, I need to round the whole invoice to 2 digits. How?
hey guys did you managed to solve this problem
Hi guys did you solve this problem