From a44184863d4b0753aca5179323acc815dd92a6ca 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: Tue, 1 Sep 2026 15:20:51 +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 --- soong_workflow/models/soong_workflow_record.py | 4 ++-- yuthon_holiday/models/inherit_hr_leave.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/soong_workflow/models/soong_workflow_record.py b/soong_workflow/models/soong_workflow_record.py index ca74ab65a..abbc1d060 100644 --- a/soong_workflow/models/soong_workflow_record.py +++ b/soong_workflow/models/soong_workflow_record.py @@ -588,11 +588,11 @@ class SoongWorkflowRecord(models.Model): user_employee.user_role_id.ids + user_employee.user_role_ids.ids ) active_company_ids = self.env.companies - active_department = user_employee.department_id + active_department = user_employee.department_id + user_employee.department_ids department_ids = [] if active_department: department_ids = self.env['hr.department'].search([ - ('id', 'child_of', active_department.id) + ('id', 'child_of', active_department.ids) ]).ids valid_employee_ids = self.env['hr.employee'].search([ ('department_id', 'in', department_ids) diff --git a/yuthon_holiday/models/inherit_hr_leave.py b/yuthon_holiday/models/inherit_hr_leave.py index 51c1331a0..0e6344348 100644 --- a/yuthon_holiday/models/inherit_hr_leave.py +++ b/yuthon_holiday/models/inherit_hr_leave.py @@ -450,8 +450,8 @@ class HolidaysRequestBatch(models.Model): 'entrust_user_id': self.users_id.id, 'entrust_user_id2': self.entrusted_agent_id.id, 'is_expiration_date': True, - 'start_date': fields.Date.today(), - 'end_date': False, + 'start_date': self.start_date, + 'end_date': self.end_date, 'entrust_notice': True, } self.env['soong.workflow.entrust'].create(entrust_vals)