From 840c5ca9d4a91c86389edfe8bb7d2f4bcede15e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=B9=8F=E5=AE=87?= <9664676+pengyuthon@user.noreply.gitee.com> Date: Fri, 8 May 2026 15:24:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yuthon_hr_attendance/models/yuthon_vacation_reports.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/yuthon_hr_attendance/models/yuthon_vacation_reports.py b/yuthon_hr_attendance/models/yuthon_vacation_reports.py index 234bc56a7..1654bac7f 100644 --- a/yuthon_hr_attendance/models/yuthon_vacation_reports.py +++ b/yuthon_hr_attendance/models/yuthon_vacation_reports.py @@ -400,7 +400,7 @@ class YuthonVacationReports(models.Model): # 2. 剩余部分扣减本年补休剩余(this_year1) if remaining_overtime_deduct > 0 and rec.this_year1 > 0: - deduct_from_current1 = min(rec.this_year1, remaining_overtime_deduct) + deduct_from_current1 = remaining_overtime_deduct rec.this_year1 -= deduct_from_current1 rec.used_this_year1 += deduct_from_current1 # 累加到本年已休 remaining_overtime_deduct -= deduct_from_current1 @@ -1706,7 +1706,7 @@ class YuthonVacationReports(models.Model): if other_line.holiday_type and other_line.holiday_type.name == '调休': adjust_holiday_days += other_line.lines or 0 - record.working_overtime = max(total_add / 8, 0) + adjust_holiday_days + record.working_overtime = (total_add / 8) + adjust_holiday_days record.done_working_overtime = total_add1 / 8 record.statutory_leave = legal_total/8 record.cop_leave = total_add2 / 8