mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-07 07:02:54 +00:00
fix: SQL query in financial statements
This commit is contained in:
@@ -350,6 +350,7 @@ def set_gl_entries_by_account(
|
||||
accounts = frappe.db.sql_list("""select name from `tabAccount`
|
||||
where lft >= %s and rgt <= %s and company = %s""", (root_lft, root_rgt, company))
|
||||
|
||||
if accounts:
|
||||
additional_conditions += " and account in ({})"\
|
||||
.format(", ".join([frappe.db.escape(d) for d in accounts]))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user