mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-31 18:59:08 +00:00
[fix] Allowed deletion of root account
This commit is contained in:
@@ -189,9 +189,6 @@ class Account(Document):
|
|||||||
|
|
||||||
def validate_trash(self):
|
def validate_trash(self):
|
||||||
"""checks gl entries and if child exists"""
|
"""checks gl entries and if child exists"""
|
||||||
if not self.parent_account:
|
|
||||||
throw(_("Root account can not be deleted"))
|
|
||||||
|
|
||||||
if self.check_gle_exists():
|
if self.check_gle_exists():
|
||||||
throw(_("Account with existing transaction can not be deleted"))
|
throw(_("Account with existing transaction can not be deleted"))
|
||||||
if self.check_if_child_exists():
|
if self.check_if_child_exists():
|
||||||
|
|||||||
Reference in New Issue
Block a user