summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Trigaux <mat@odoo.com>2016-10-20 09:55:19 +0200
committerMartin Trigaux <mat@odoo.com>2016-10-20 09:55:31 +0200
commit26bbfc46f628d3055ed018bf751ad4584bca18de (patch)
treec7b663e1c4ff5f16f0389f2152be77d1bd71cc66
parent326ef2301e0ea53549e1dd3f9049ec8dc33e1b3b (diff)
[FIX] stock_account: stop comparing apples and oranges
company_currency is a recordset, not an id Introduced at 19199457 Closes #13707
-rw-r--r--addons/stock_account/models/account_invoice.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/stock_account/models/account_invoice.py b/addons/stock_account/models/account_invoice.py
index 5dba13166ae..115006e4c48 100644
--- a/addons/stock_account/models/account_invoice.py
+++ b/addons/stock_account/models/account_invoice.py
@@ -76,7 +76,7 @@ class AccountInvoiceLine(models.Model):
return self.product_id.standard_price
def _get_price(self, company_currency, price_unit):
- if self.invoice_id.currency_id.id != company_currency:
+ if self.invoice_id.currency_id.id != company_currency.id:
price = company_currency.with_context(date=self.invoice_id.date_invoice).compute(price_unit * self.quantity, self.invoice_id.currency_id)
else:
price = price_unit * self.quantity