添加功能

This commit is contained in:
zhou
2025-04-03 22:05:53 +08:00
parent 7eab51494c
commit 71f4087c1e
24 changed files with 189 additions and 108 deletions
@@ -18,7 +18,10 @@ class YuthonMedicalManage(models.Model):
prev_last_year_balance = fields.Float(string="前年结余")
prev_last_year_used = fields.Float(string="前年使用")
prev_last_year_remaining = fields.Float(string="前年剩余")
this_year_usage = fields.Float(string='本年使用')
this_year_quota = fields.Float(string='本年额度')
medical_line_ids = fields.One2many('yuthon.medical.line', 'medical_manage_id', string="体检费明细")
company_id = fields.Many2one("res.company", string="公司", default=lambda self: self.env.company)
def button_details(self):
form_id = self.env.ref('yuthon_hr_employee.view_yuthon_medical_manage_form').id
@@ -30,6 +33,15 @@ class YuthonMedicalManage(models.Model):
"res_id": self.id,
}
def property_reimbursement_form(self):
form_id = self.env.ref('yuthon_hr_employee_approval.view_property_reimbursement_form_form').id
return {
"type": "ir.actions.act_window",
"name": "报销单",
"res_model": "property.reimbursement.form",
"views": [[form_id, "form"]],
}
class YuthonMedicalLine(models.Model):
_name = 'yuthon.medical.line'
_description = '体检费明细'