!10403 添加功能

Merge pull request !10403 from 李鹏宇/dev_zhou
This commit is contained in:
李鹏宇
2026-03-31 02:16:35 +00:00
committed by Gitee
@@ -259,10 +259,10 @@ class OvertimeApprovals(models.Model):
if actual_start < base_start:
total_overtime_seconds += (base_start - actual_start).total_seconds()
if actual_end > base_end:
total_overtime_seconds += (actual_end - base_end).total_seconds()
real_overtime_start = max(base_end, actual_start)
total_overtime_seconds += (actual_end - real_overtime_start).total_seconds()
else:
total_overtime_seconds = (actual_end - actual_start).total_seconds()
original_hours = total_overtime_seconds / 3600
# 加班起步一小时
if original_hours < 1.0: