[FIX] account: invoice lines amounts must be rounded when converted to journal items

This revision is related to cfbd086b09.
This is the same use case than above, but with a different
currency than the one of the company, for the field
`amount_currency` this time.

Closes #8135
opw-647639
This commit is contained in:
Denis Ledoux 2015-08-24 18:16:05 +02:00
parent 9a9720ac14
commit 802d1abe7a
1 changed files with 1 additions and 1 deletions

View File

@ -739,7 +739,7 @@ class account_invoice(models.Model):
if self.currency_id != company_currency:
currency = self.currency_id.with_context(date=self.date_invoice or fields.Date.context_today(self))
line['currency_id'] = currency.id
line['amount_currency'] = line['price']
line['amount_currency'] = currency.round(line['price'])
line['price'] = currency.compute(line['price'], company_currency)
else:
line['currency_id'] = False