From 0db423ed5f6801631d5f07a7e4c1ca323bdeb9b2 Mon Sep 17 00:00:00 2001 From: Karthikeyan S Date: Fri, 28 Feb 2020 12:27:21 +0530 Subject: [PATCH] fix(auto attendance): bug in marking absent (#20759) This bug was introduces in the commit bd6e8b9cec5414f81c67468030ec174030845720 i.e. The mark_absent function was renamed to mark_attendance, but there is a miss match in the order of the parameters. --- erpnext/hr/doctype/shift_type/shift_type.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/hr/doctype/shift_type/shift_type.py b/erpnext/hr/doctype/shift_type/shift_type.py index 49884103e21..d56080eecd4 100644 --- a/erpnext/hr/doctype/shift_type/shift_type.py +++ b/erpnext/hr/doctype/shift_type/shift_type.py @@ -75,7 +75,7 @@ class ShiftType(Document): for date in dates: shift_details = get_employee_shift(employee, date, True) if shift_details and shift_details.shift_type.name == self.name: - mark_attendance(employee, date, self.name, 'Absent') + mark_attendance(employee, date, 'Absent', self.name) def get_assigned_employee(self, from_date=None, consider_default_shift=False): filters = {'date':('>=', from_date), 'shift_type': self.name, 'docstatus': '1'}