Merge pull request #47917 from frappe/mergify/bp/version-15-hotfix/pr-47907

feat: Add hook to update gl dict by apps (backport #47907)
This commit is contained in:
Deepesh Garg
2025-06-05 16:51:20 +05:30
committed by GitHub

View File

@@ -1151,6 +1151,8 @@ class AccountsController(TransactionBase):
with temporary_flag("company", self.company):
update_gl_dict_with_regional_fields(self, gl_dict)
update_gl_dict_with_app_based_fields(self, gl_dict)
accounting_dimensions = get_accounting_dimensions()
dimension_dict = frappe._dict()
@@ -3937,3 +3939,8 @@ def validate_einvoice_fields(doc):
@erpnext.allow_regional
def update_gl_dict_with_regional_fields(doc, gl_dict):
pass
def update_gl_dict_with_app_based_fields(doc, gl_dict):
for method in frappe.get_hooks("update_gl_dict_with_app_based_fields", default=[]):
frappe.get_attr(method)(doc, gl_dict)