diff --git a/erpnext/accounts/deferred_revenue.py b/erpnext/accounts/deferred_revenue.py index cd34bf7f8501..a88764cf1b2f 100644 --- a/erpnext/accounts/deferred_revenue.py +++ b/erpnext/accounts/deferred_revenue.py @@ -58,7 +58,7 @@ def build_conditions(process_type, account, company): ) if account: - conditions += f"AND {deferred_account}='{frappe.db.escape(account)}'" + conditions += f"AND {deferred_account}={frappe.db.escape(account)}" elif company: conditions += f"AND p.company = {frappe.db.escape(company)}" diff --git a/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.py b/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.py index 1954b4b0efe1..7c843cf552ef 100644 --- a/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.py +++ b/erpnext/accounts/doctype/accounting_dimension_filter/accounting_dimension_filter.py @@ -74,12 +74,12 @@ def get_dimension_filter_map(): a.applicable_on_account, d.dimension_value, p.accounting_dimension, p.allow_or_restrict, a.is_mandatory FROM - `tabApplicable On Account` a, `tabAllowed Dimension` d, + `tabApplicable On Account` a, `tabAccounting Dimension Filter` p + LEFT JOIN `tabAllowed Dimension` d ON d.parent = p.name WHERE p.name = a.parent AND p.disabled = 0 - AND p.name = d.parent """, as_dict=1, ) @@ -97,7 +97,6 @@ def get_dimension_filter_map(): f.allow_or_restrict, f.is_mandatory, ) - frappe.flags.dimension_filter_map = dimension_filter_map return frappe.flags.dimension_filter_map diff --git a/erpnext/accounts/doctype/pos_invoice_merge_log/pos_invoice_merge_log.py b/erpnext/accounts/doctype/pos_invoice_merge_log/pos_invoice_merge_log.py index aecdac0b3a1e..5bb43b3fa723 100644 --- a/erpnext/accounts/doctype/pos_invoice_merge_log/pos_invoice_merge_log.py +++ b/erpnext/accounts/doctype/pos_invoice_merge_log/pos_invoice_merge_log.py @@ -438,7 +438,9 @@ def split_invoices(invoices): if not item.serial_no and not item.serial_and_batch_bundle: continue - return_against_is_added = any(d for d in _invoices if d.pos_invoice == pos_invoice.return_against) + return_against_is_added = any( + d for d in _invoices if d and d[0].pos_invoice == pos_invoice.return_against + ) if return_against_is_added: break diff --git a/erpnext/templates/pages/projects.py b/erpnext/templates/pages/projects.py index e3e26fc82a6f..787c7c0069b1 100644 --- a/erpnext/templates/pages/projects.py +++ b/erpnext/templates/pages/projects.py @@ -51,7 +51,7 @@ def get_tasks(project, start=0, search=None, item_status=None): "parent_task", ], limit_start=start, - limit_page_length=10, + limit_page_length=100, ) task_nest = [] for task in tasks: