From 04ca9cccc6d7289977f42e1eceb16fae4f7725f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=B9=8F=E5=AE=87?= Date: Thu, 27 Mar 2025 22:16:03 +0800 Subject: [PATCH] 1 --- yuthon_salary/models/inherit_hr_payslip.py | 3 ++- yuthon_salary/models/yuthon_payroll_project.py | 2 +- yuthon_salary/views/inherit_hr_payslip_views.xml | 2 ++ 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/yuthon_salary/models/inherit_hr_payslip.py b/yuthon_salary/models/inherit_hr_payslip.py index b7b5f3612..143bd4333 100644 --- a/yuthon_salary/models/inherit_hr_payslip.py +++ b/yuthon_salary/models/inherit_hr_payslip.py @@ -69,6 +69,7 @@ class InheritHrPayslip(models.Model): tax_reduction = fields.Float(string='减免税额') deduction_standard = fields.Float(string='减除费用标准') paid_tax = fields.Float(string='已缴税额') + based_pay = fields.Float(string='临时绩效工资') performance_deduction = fields.Float(string='扣发绩效奖金', store=True) attendance_deduction = fields.Float(string='扣发全勤奖', store=True) @@ -185,7 +186,7 @@ class InheritHrPayslip(models.Model): for line in record.line_ids: if line.name in name_list: total += line.total - record.total_before_tax = total + record.base_salary + record.performance_bonuses + record.rank_salary + record.year_compute + record.year_jie + record.year_gong, record.jing_te + record.total_before_tax = total + record.base_salary + record.performance_bonuses + record.rank_salary + record.year_compute + record.year_jie + record.year_gong + record.jing_te def put_button(self): for record in self: diff --git a/yuthon_salary/models/yuthon_payroll_project.py b/yuthon_salary/models/yuthon_payroll_project.py index af80b6875..a30fcd44c 100644 --- a/yuthon_salary/models/yuthon_payroll_project.py +++ b/yuthon_salary/models/yuthon_payroll_project.py @@ -189,7 +189,7 @@ class YuthonPayrollInsurances (models.Model): formula_salary = "result = employee.work_injury_insurance_base * " + str(number) if ins.name == '住房公积金': code = 'ZFGJJ' - formula_salary = "result = employee.housing_fund_base * " + str(number) + formula_salary = "result = round((employee.housing_fund_base * " + str(number) + "), 2)" if ins.name == '工会会费': code = 'GHHF' formula_salary = "result = round((payslip.base_salary * 0.005), 2)" diff --git a/yuthon_salary/views/inherit_hr_payslip_views.xml b/yuthon_salary/views/inherit_hr_payslip_views.xml index 9cf07f342..46811372b 100644 --- a/yuthon_salary/views/inherit_hr_payslip_views.xml +++ b/yuthon_salary/views/inherit_hr_payslip_views.xml @@ -44,6 +44,7 @@ + @@ -54,6 +55,7 @@ +