!8856 出勤详情按钮优化

Merge pull request !8856 from 李鹏宇/dev
This commit is contained in:
李鹏宇
2026-02-10 06:42:28 +00:00
committed by Gitee
+6 -6
View File
@@ -671,12 +671,12 @@ class HrAttendance(models.Model):
('checkin_time', '>=', start_datetime),
('checkin_time', '<', check_out_end - timedelta(hours=8))
]
if '行政' in template.display_name:
domain = [
('employee_id', '=', employee_id.id),
('checkin_time', '>=', current_date),
('checkin_time', '<', next_day)
]
# if '行政' in template.display_name:
# domain = [
# ('employee_id', '=', employee_id.id),
# ('checkin_time', '>=', current_date),
# ('checkin_time', '<', next_day)
# ]
attendance_records = self.env['hr.attendance.detail'].search(domain)
if attendance_records:
action = {