From 8a377a190d30176b04eeaaae5d275cb197a17626 Mon Sep 17 00:00:00 2001 From: paulius <> Date: Tue, 1 May 2012 11:44:12 +0530 Subject: [PATCH] [FIX] improve rounding at invoice subtotal field--fixes=lp:977300 bzr revid: rmu@tinyerp.com-20120501061412-on9rz3lkbm7oqad3 --- addons/account/account.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/account/account.py b/addons/account/account.py index 75bfc891980..63f0e0ec1a7 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -29,6 +29,7 @@ import pooler from osv import fields, osv import decimal_precision as dp from tools.translate import _ +from tools import float_round def check_cycle(self, cr, uid, ids, context=None): """ climbs the ``self._table.parent_id`` chains for 100 levels or @@ -2069,7 +2070,7 @@ class account_tax(osv.osv): } """ precision = self.pool.get('decimal.precision').precision_get(cr, uid, 'Account') - totalin = totalex = round(price_unit * quantity, precision) + totalin = totalex = float_round(price_unit * quantity, precision) tin = [] tex = [] for tax in taxes: