summaryrefslogtreecommitdiff
path: root/addons
diff options
context:
space:
mode:
authorqdp-odoo <qdp@odoo.com>2016-06-21 11:01:07 +0200
committerqdp-odoo <qdp@odoo.com>2016-06-22 08:25:17 +0200
commitb8a58caad113c14ccd89cef28982b54a9d64a45b (patch)
tree00c4bfb1f39dbb190b1b8cc3975d1a165140c6c2 /addons
parent108eee76c55b98d9c7cd51d4f525bc95d77a32eb (diff)
[FIX] account: in the bank statement reconciliation widget, don't convert amounts using the amount_currency to the target currency if the target currency is the compmany currency. OPW 680854
Diffstat (limited to 'addons')
-rw-r--r--addons/account/models/account_move.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/account/models/account_move.py b/addons/account/models/account_move.py
index 376a75cedd0..0716485c708 100644
--- a/addons/account/models/account_move.py
+++ b/addons/account/models/account_move.py
@@ -675,7 +675,7 @@ class AccountMoveLine(models.Model):
line_currency = (line.currency_id and line.amount_currency) and line.currency_id or company_currency
amount_currency_str = ""
total_amount_currency_str = ""
- if line_currency != company_currency:
+ if line_currency != company_currency and target_currency != company_currency:
total_amount = line.amount_currency
actual_debit = debit > 0 and amount_currency or 0.0
actual_credit = credit > 0 and -amount_currency or 0.0
@@ -683,7 +683,7 @@ class AccountMoveLine(models.Model):
total_amount = abs(debit - credit)
actual_debit = debit > 0 and amount or 0.0
actual_credit = credit > 0 and -amount or 0.0
- if line_currency != target_currency:
+ if line_currency != target_currency and target_currency != company_currency:
amount_currency_str = formatLang(self.env, abs(actual_debit or actual_credit), currency_obj=line_currency)
total_amount_currency_str = formatLang(self.env, total_amount, currency_obj=line_currency)
ctx = context.copy()