mirror of
https://github.com/OCA/account-reconcile.git
synced 2025-01-20 12:27:39 +02:00
[FIX] account_reconcile_analytic_tag: Avoid error when accessing the reconciliation view
Steps to reproduce the error: - Go to Accounting Dashboard - Click on the Reconcile X items button of the bank journal
This commit is contained in:
@@ -14,7 +14,8 @@ class AccountReconcileModel(models.Model):
|
|||||||
if len(res) == 0:
|
if len(res) == 0:
|
||||||
return res
|
return res
|
||||||
currency = self.company_id.currency_id
|
currency = self.company_id.currency_id
|
||||||
for index, line in enumerate(self.line_ids):
|
index = 0
|
||||||
|
for line in self.line_ids:
|
||||||
if line.amount_type == "percentage":
|
if line.amount_type == "percentage":
|
||||||
balance = currency.round(residual_balance * (line.amount / 100.0))
|
balance = currency.round(residual_balance * (line.amount / 100.0))
|
||||||
elif line.amount_type == "fixed":
|
elif line.amount_type == "fixed":
|
||||||
@@ -28,6 +29,7 @@ class AccountReconcileModel(models.Model):
|
|||||||
continue
|
continue
|
||||||
|
|
||||||
res[index]["manual_analytic_tag_ids"] = [(6, 0, line.analytic_tag_ids.ids)]
|
res[index]["manual_analytic_tag_ids"] = [(6, 0, line.analytic_tag_ids.ids)]
|
||||||
|
index += 1
|
||||||
return res
|
return res
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user