diff --git a/yuthon_salary/wizard/salary_compute_wizard.py b/yuthon_salary/wizard/salary_compute_wizard.py index 27a073a9e..cd27a4e49 100644 --- a/yuthon_salary/wizard/salary_compute_wizard.py +++ b/yuthon_salary/wizard/salary_compute_wizard.py @@ -109,7 +109,7 @@ class SalaryComputeWizard(models.Model): for line in internship_id.line_ids: if line.name in target_names: result = line.total * 0.8 - line.total = result + line.write({'total': result}) elif contract_end_date.year == end_date.year and contract_end_date.month == end_date.month: leave_days = self._create_leave_record(start_date, end_date) days = leave_days.number_of_days @@ -128,7 +128,7 @@ class SalaryComputeWizard(models.Model): for line in internship_id.line_ids: if line.name in target_names: result = line.total * 0.8 * internship_days / days + line.total * 0.8 * work_days / days - line.total = result + line.write({'total': result}) def _get_chinese_month(self, month): chinese_months = ['一月', '二月', '三月', '四月', '五月', '六月', '七月', '八月', '九月', '十月', '十一月', '十二月']