mirror of
https://github.com/OCA/account-reconcile.git
synced 2025-01-20 12:27:39 +02:00
[IMP] account_reconciliation_widget: show analytic account on counterpart line
This commit is contained in:
@@ -911,6 +911,7 @@ class AccountReconciliation(models.AbstractModel):
|
||||
"already_paid": line.account_id.internal_type == "liquidity",
|
||||
"account_code": line.account_id.code,
|
||||
"account_name": line.account_id.name,
|
||||
"analytic_account_code": line.analytic_account_id.display_name or "",
|
||||
"account_type": line.account_id.internal_type,
|
||||
"date_maturity": format_date(self.env, line.date_maturity),
|
||||
"date": format_date(self.env, line.date),
|
||||
@@ -1021,6 +1022,8 @@ class AccountReconciliation(models.AbstractModel):
|
||||
"""Returns the data required by the bank statement reconciliation
|
||||
widget to display a statement line"""
|
||||
|
||||
group_analytic = self.env.user.has_group("analytic.group_analytic_accounting")
|
||||
group_analytic_tags = self.env.user.has_group("analytic.group_analytic_tags")
|
||||
statement_currency = (
|
||||
st_line.journal_id.currency_id or st_line.journal_id.company_id.currency_id
|
||||
)
|
||||
@@ -1067,6 +1070,8 @@ class AccountReconciliation(models.AbstractModel):
|
||||
"amount_currency": amount_currency,
|
||||
"has_no_partner": not st_line.partner_id.id,
|
||||
"company_id": st_line.company_id.id,
|
||||
"group_analytic_accounting": group_analytic,
|
||||
"group_analytic_tags": group_analytic_tags,
|
||||
}
|
||||
if st_line.partner_id:
|
||||
data["open_balance_account_id"] = (
|
||||
|
||||
Reference in New Issue
Block a user