From 69b2da20a8957c59b826ad6ae4ff56ef643b5c8a Mon Sep 17 00:00:00 2001 From: zhouzhou <123@qq.com> Date: Fri, 25 Oct 2024 18:58:13 +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 --- .../data/attendance_code_data.xml | 2 +- yuthon_issue/models/issue_library.py | 18 +- yuthon_issue/security/ir.model.access.csv | 1 - yuthon_issue/views/issue_library_views.xml | 1323 +++++++++++++++-- yuthon_performance/__manifest__.py | 2 +- .../data/library_changes_data.xml | 14 + yuthon_performance/models/__init__.py | 4 +- .../models/yuthon_Index_management.py | 1 - .../models/yuthon_duty_approval.py | 19 - .../models/yuthon_duty_management.py | 31 +- .../models/yuthon_employee_appraisal.py | 4 +- .../models/yuthon_tissue_duty_approval.py | 93 ++ .../security/ir.model.access.csv | 6 +- .../views/yuthon_Index_approval.xml | 38 +- .../views/yuthon_duty_approval.xml | 91 -- .../views/yuthon_duty_management.xml | 1 + .../views/yuthon_employee_approval.xml | 25 +- .../views/yuthon_performance_menus.xml | 33 - .../views/yuthon_tissue_duty_approval.xml | 114 ++ yuthon_property/__manifest__.py | 2 + .../data/yuthon_property_approval_data.xml | 11 + yuthon_property/models/__init__.py | 1 + .../models/property_evaluate_application.py | 19 + .../models/property_rental_form.py | 22 + yuthon_property/models/yuthon_property.py | 2 +- .../models/yuthon_property_evaluation.py | 4 + .../models/yuthon_resource_mgmt_config.py | 13 - yuthon_property/security/ir.model.access.csv | 21 +- yuthon_property/views/menuitem.xml | 10 +- .../property_evaluate_application_views.xml | 71 + .../views/property_rental_form_views.xml | 72 + .../yuthon_property_evaluation_views.xml | 2 +- .../views/yuthon_property_views.xml | 28 +- .../yuthon_resource_mgmt_config_views.xml | 19 - yuthon_work_brand/views/hr_menus.xml | 5 + 35 files changed, 1771 insertions(+), 351 deletions(-) delete mode 100644 yuthon_performance/models/yuthon_duty_approval.py create mode 100644 yuthon_performance/models/yuthon_tissue_duty_approval.py delete mode 100644 yuthon_performance/views/yuthon_duty_approval.xml create mode 100644 yuthon_performance/views/yuthon_tissue_duty_approval.xml create mode 100644 yuthon_property/data/yuthon_property_approval_data.xml create mode 100644 yuthon_property/models/property_evaluate_application.py create mode 100644 yuthon_property/models/property_rental_form.py create mode 100644 yuthon_property/views/property_evaluate_application_views.xml create mode 100644 yuthon_property/views/property_rental_form_views.xml diff --git a/yuthon_hr_attendance/data/attendance_code_data.xml b/yuthon_hr_attendance/data/attendance_code_data.xml index 5fb0bf200..3bdd7c20a 100644 --- a/yuthon_hr_attendance/data/attendance_code_data.xml +++ b/yuthon_hr_attendance/data/attendance_code_data.xml @@ -1,4 +1,4 @@ - + 加班申请序列号 diff --git a/yuthon_issue/models/issue_library.py b/yuthon_issue/models/issue_library.py index e3ab2a6af..9dcf65458 100644 --- a/yuthon_issue/models/issue_library.py +++ b/yuthon_issue/models/issue_library.py @@ -10,6 +10,7 @@ class IssueLibrary(models.Model): _rec_name = 'name' name = fields.Char(string='议题事项') + name_text = fields.Text(string='议题事项') code = fields.Char(string='编号', required=True, copy=False, default=lambda self: self.env['ir.sequence'].next_by_code('issue_library_code')) state = fields.Selection([('draft', '待提交'), ('approval', '审批中'), ('on_approval', '已审批'), @@ -28,7 +29,9 @@ class IssueLibrary(models.Model): issue_library_approval_line_ids = fields.One2many('issue.library.approval.line', 'issue_library_id', string='流程记录') approval_decision_sequence = fields.Char(string="决策清单事项") is_booking = fields.Boolean(string="是否上会") - + cs_party = fields.Char(string='党支委') + cs_class = fields.Char(string='班子会') + cs_boss = fields.Char(string='董事会') issue_library_room_line_ids = fields.One2many('issue.library.room.line', 'issue_library_id', string="关联会议明细行") # 权限相关隐藏字段 employee_id = fields.Many2one('hr.employee', string='创建人', default=lambda self: self.env.user.employee_id) @@ -145,7 +148,20 @@ class IssueLibrary(models.Model): raise UserError('议题已上会,不能删除') return super().unlink() + @api.onchange('name') + def _onchange_name(self): + self.name_text = self.name + + @api.onchange('issue_library_room_line_ids') + def _onchange_issue_library_room_line_ids(self): + for record in self.issue_library_room_line_ids: + if record.meeting_type_id.name == '党委会': + self.cs_party = record.room_booking_id.name + elif record.meeting_type_id.name == '班子会': + self.cs_class = record.room_booking_id.name + elif record.meeting_type_id.name == '董事会': + self.cs_boss = record.room_booking_id.name class IssueLibraryLine(models.Model): _name = "issue.library.line" _description = '决策清单' diff --git a/yuthon_issue/security/ir.model.access.csv b/yuthon_issue/security/ir.model.access.csv index 1fb92bec8..dbdb7cd23 100644 --- a/yuthon_issue/security/ir.model.access.csv +++ b/yuthon_issue/security/ir.model.access.csv @@ -10,4 +10,3 @@ access_issue_meeting_minutes_line,issue_meeting_minutes_line,model_issue_meeting access_issue_meeting_minutes,issue_meeting_minutes,model_issue_meeting_minutes,base.group_user,1,1,1,1 access_issue_meeting_line,issue_meeting_line,model_issue_meeting_line,base.group_user,1,1,1,1 access_issue_library_room_line,issue_library_room_line,model_issue_library_room_line,base.group_user,1,1,1,1 - diff --git a/yuthon_issue/views/issue_library_views.xml b/yuthon_issue/views/issue_library_views.xml index 60423eaa0..04c197f8a 100644 --- a/yuthon_issue/views/issue_library_views.xml +++ b/yuthon_issue/views/issue_library_views.xml @@ -1,6 +1,6 @@ - + issue.library.tree issue.library @@ -8,8 +8,9 @@ decoration-info="state == 'will'" decoration-success="state == 'done'" decoration-muted="state == 'cancel'"> - + + @@ -36,6 +37,7 @@ + @@ -63,6 +65,124 @@ + + + + + + + + + + + + + + + + + + + + + + +