Merge pull request #33303 from ruthra-kumar/incorrect_balance_on_consolidate_balance_sheet
fix: incorrect balance on parent company on consolidate Balance sheet due to key mismatch
This commit is contained in:
commit
2175784142
@ -533,12 +533,13 @@ def get_accounts(root_type, companies):
|
|||||||
],
|
],
|
||||||
filters={"company": company, "root_type": root_type},
|
filters={"company": company, "root_type": root_type},
|
||||||
):
|
):
|
||||||
if account.account_name not in added_accounts:
|
if account.account_number:
|
||||||
|
account_key = account.account_number + "-" + account.account_name
|
||||||
|
else:
|
||||||
|
account_key = account.account_name
|
||||||
|
|
||||||
|
if account_key not in added_accounts:
|
||||||
accounts.append(account)
|
accounts.append(account)
|
||||||
if account.account_number:
|
|
||||||
account_key = account.account_number + "-" + account.account_name
|
|
||||||
else:
|
|
||||||
account_key = account.account_name
|
|
||||||
added_accounts.append(account_key)
|
added_accounts.append(account_key)
|
||||||
|
|
||||||
return accounts
|
return accounts
|
||||||
|
Loading…
x
Reference in New Issue
Block a user