Skip to content

Commit

Permalink
Merge pull request #38580 from ruthra-kumar/finance_book_filter_bug_i…
Browse files Browse the repository at this point in the history
…n_general_ledger

fix: sql error while filtering on finance book in GL
  • Loading branch information
ruthra-kumar authored Dec 5, 2023
2 parents aaa9036 + b1d9f31 commit 5da3e53
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion erpnext/accounts/report/general_ledger/general_ledger.py
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,8 @@ def get_conditions(filters):

if accounting_dimensions:
for dimension in accounting_dimensions:
if not dimension.disabled:
# Ignore 'Finance Book' set up as dimension in below logic, as it is already handled in above section
if not dimension.disabled and dimension.document_type != "Finance Book":
if filters.get(dimension.fieldname):
if frappe.get_cached_value("DocType", dimension.document_type, "is_tree"):
filters[dimension.fieldname] = get_dimension_with_children(
Expand Down

0 comments on commit 5da3e53

Please sign in to comment.