From 01add1fe1585aaba2fa40a711332dee04859e48b Mon Sep 17 00:00:00 2001 From: Thomas Binsfeld Date: Thu, 6 Apr 2017 15:10:34 +0200 Subject: [PATCH] [FIX] account: browse only one record Part of #16282 --- addons/account/models/account_move.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/account/models/account_move.py b/addons/account/models/account_move.py index e1d8f8d7532..40185e9f510 100644 --- a/addons/account/models/account_move.py +++ b/addons/account/models/account_move.py @@ -1346,9 +1346,9 @@ class AccountPartialReconcile(models.Model): for rec in self: if not rec.company_id.currency_exchange_journal_id: raise UserError(_("You should configure the 'Exchange Rate Journal' in the accounting settings, to manage automatically the booking of accounting entries related to differences between exchange rates.")) - if not self.company_id.income_currency_exchange_account_id.id: + if not rec.company_id.income_currency_exchange_account_id.id: raise UserError(_("You should configure the 'Gain Exchange Rate Account' in the accounting settings, to manage automatically the booking of accounting entries related to differences between exchange rates.")) - if not self.company_id.expense_currency_exchange_account_id.id: + if not rec.company_id.expense_currency_exchange_account_id.id: raise UserError(_("You should configure the 'Loss Exchange Rate Account' in the accounting settings, to manage automatically the booking of accounting entries related to differences between exchange rates.")) move_vals = {'journal_id': rec.company_id.currency_exchange_journal_id.id, 'rate_diff_partial_rec_id': rec.id}