diff --git a/yuthon_holiday/models/inherit_hr_leave_allocation.py b/yuthon_holiday/models/inherit_hr_leave_allocation.py index 2a0642637..477f5b2d0 100644 --- a/yuthon_holiday/models/inherit_hr_leave_allocation.py +++ b/yuthon_holiday/models/inherit_hr_leave_allocation.py @@ -87,6 +87,8 @@ class HrLeaveAllocation(models.Model): now_type = 'hours' else: now_type = 'days' + self.write({'is_approval': True, 'is_abnormal': False, 'is_no_card': False, + 'is_early_card': False, 'is_late_card': False}) return { "type": "ir.actions.act_window", "name": "修正申请", @@ -101,7 +103,6 @@ class HrLeaveAllocation(models.Model): 'default_original_hours': self.number_of_days_display, } } - def all_refuse(self): leave_ids = self.env["hr.leave.allocation"].browse( self._context.get('active_ids', self._context.get('active_id'))) diff --git a/yuthon_hr_attendance/views/hr_attendance_views.xml b/yuthon_hr_attendance/views/hr_attendance_views.xml index 754245938..70cad3736 100644 --- a/yuthon_hr_attendance/views/hr_attendance_views.xml +++ b/yuthon_hr_attendance/views/hr_attendance_views.xml @@ -49,6 +49,15 @@ + + hr.attendance.search + hr.attendance + + + + + + 出勤 hr.attendance @@ -59,12 +68,14 @@ hr.attendance tree,form [('employee_id.resource_calendar_id.name', '=', '行政考勤')] + 我的考勤 hr.attendance tree,form,search [('employee_id.user_id', '=', uid)] + 考勤记录