Skip to content

Commit

Permalink
fix: filter by cost center in trial balance
Browse files Browse the repository at this point in the history
(cherry picked from commit 02428b4)
  • Loading branch information
GursheenK authored and mergify[bot] committed Jul 26, 2023
1 parent c4b0790 commit a20d78a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion erpnext/accounts/report/trial_balance/trial_balance.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ def get_opening_balance(
lft, rgt = frappe.db.get_value("Cost Center", filters.cost_center, ["lft", "rgt"])
cost_center = frappe.qb.DocType("Cost Center")
opening_balance = opening_balance.where(
closing_balance.cost_center.in_(
closing_balance.cost_center.isin(
frappe.qb.from_(cost_center)
.select("name")
.where((cost_center.lft >= lft) & (cost_center.rgt <= rgt))
Expand Down

0 comments on commit a20d78a

Please sign in to comment.