test: basic tests for controllers/queries (#27422)

This commit is contained in:
Ankush Menat
2021-09-10 12:46:35 +05:30
committed by GitHub
parent 3da34382b5
commit 62fc544280
2 changed files with 88 additions and 1 deletions

View File

@@ -307,7 +307,7 @@ def bom(doctype, txt, searchfield, start, page_len, filters):
@frappe.validate_and_sanitize_search_inputs
def get_project_name(doctype, txt, searchfield, start, page_len, filters):
cond = ''
if filters.get('customer'):
if filters and filters.get('customer'):
cond = """(`tabProject`.customer = %s or
ifnull(`tabProject`.customer,"")="") and""" %(frappe.db.escape(filters.get("customer")))