mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-04 05:58:27 +00:00
fix: not able to add equity account in the chart of accounts
This commit is contained in:
@@ -102,7 +102,7 @@ class Account(NestedSet):
|
|||||||
if not frappe.db.get_value("Account",
|
if not frappe.db.get_value("Account",
|
||||||
{'account_name': self.account_name, 'company': ancestors[0]}, 'name'):
|
{'account_name': self.account_name, 'company': ancestors[0]}, 'name'):
|
||||||
frappe.throw(_("Please add the account to root level Company - %s" % ancestors[0]))
|
frappe.throw(_("Please add the account to root level Company - %s" % ancestors[0]))
|
||||||
else:
|
elif self.parent_account:
|
||||||
descendants = get_descendants_of('Company', self.company)
|
descendants = get_descendants_of('Company', self.company)
|
||||||
if not descendants: return
|
if not descendants: return
|
||||||
parent_acc_name_map = {}
|
parent_acc_name_map = {}
|
||||||
|
|||||||
Reference in New Issue
Block a user