Merge pull request #17038 from netchampfaris/fix-leave-application-condition
fix: Missing "and" in filter conditions
This commit is contained in:
commit
4873875c1c
@ -512,7 +512,7 @@ def add_department_leaves(events, start, end, employee, company):
|
|||||||
department_employees = frappe.db.sql_list("""select name from tabEmployee where department=%s
|
department_employees = frappe.db.sql_list("""select name from tabEmployee where department=%s
|
||||||
and company=%s""", (department, company))
|
and company=%s""", (department, company))
|
||||||
|
|
||||||
filter_conditions = "employee in (\"%s\")" % '", "'.join(department_employees)
|
filter_conditions = " and employee in (\"%s\")" % '", "'.join(department_employees)
|
||||||
add_leaves(events, start, end, filter_conditions=filter_conditions)
|
add_leaves(events, start, end, filter_conditions=filter_conditions)
|
||||||
|
|
||||||
def add_leaves(events, start, end, filter_conditions=None):
|
def add_leaves(events, start, end, filter_conditions=None):
|
||||||
|
Loading…
Reference in New Issue
Block a user