diff --git a/move.py b/move.py index 7d9a44c750..9ddc434c87 100644 --- a/move.py +++ b/move.py @@ -526,6 +526,7 @@ class Line(OSV): tax_obj = self.pool.get('account.tax') account_obj = self.pool.get('account.account') tax_code_obj = self.pool.get('account.tax.code') + currency_obj = self.pool.get('currency.currency') values = super(Line, self).default_get(cursor, user, fields, context=context) @@ -638,6 +639,10 @@ class Line(OSV): line_amount -= tax_line['amount'] tax_amount += tax_line['amount'] * \ tax_line['tax'][key + '_tax_sign'] + line_amount = currency_obj.round(cursor, user, + line.account.company.currency, line_amount) + tax_amount = currency_obj.round(cursor, user, + line.account.company.currency, tax_amount) if ('debit' in fields): values['debit'] = line_amount > Decimal('0.0') \ and line_amount or Decimal('0.0')