-
+
→
From ba3d17dd778435554e089169208ca081a55cab66 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: Wed, 24 Dec 2025 10:38:39 +0800
Subject: [PATCH 07/71] =?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
---
yuthon_will_task/models/yuthon_will_task.py | 48 ++++++++++-----------
1 file changed, 24 insertions(+), 24 deletions(-)
diff --git a/yuthon_will_task/models/yuthon_will_task.py b/yuthon_will_task/models/yuthon_will_task.py
index 64e12af08..ce46e98d7 100644
--- a/yuthon_will_task/models/yuthon_will_task.py
+++ b/yuthon_will_task/models/yuthon_will_task.py
@@ -123,30 +123,30 @@ class YuthonWillTask(models.Model):
if record.start_date:
date_str = record.start_date.strftime("%Y/%m/%d")
hour_mapping = {
- '0': '0:00', '0.5': '0:30',
- '1': '01:00', '1.5': '01:30',
- '2': '02:00', '2.5': '02:30',
- '3': '03:00', '3.5': '03:30',
- '4': '04:00', '4.5': '04:30',
- '5': '05:00', '5.5': '05:30',
- '6': '06:00', '6.5': '06:30',
- '7': '07:00', '7.5': '07:30',
- '8': '08:00', '8.5': '08:30',
- '9': '09:00', '9.5': '09:30',
- '10': '10:00', '10.5': '10:30',
- '11': '11:00', '11.5': '11:30',
- '12': '12:00', '12.5': '12:30',
- '13': '13:00', '13.5': '13:30',
- '14': '14:00', '14.5': '14:30',
- '15': '15:00', '15.5': '15:30',
- '16': '16:00', '16.5': '16:30',
- '17': '17:00', '17.5': '17:30',
- '18': '18:00', '18.5': '18:30',
- '19': '19:00', '19.5': '19:30',
- '20': '20:00', '20.5': '20:30',
- '21': '21:00', '21.5': '21:30',
- '22': '22:00', '22.5': '22:30',
- '23': '23:00', '23.5': '23:30'
+ '0': '0:00', '0.25': '0:15', '0.5': '0:30', '0.75': '0:45',
+ '1': '01:00', '1.25': '01:15', '1.5': '01:30', '1.75': '01:45',
+ '2': '02:00', '2.25': '02:15', '2.5': '02:30', '2.75': '02:45',
+ '3': '03:00', '3.25': '03:15', '3.5': '03:30', '3.75': '03:45',
+ '4': '04:00', '4.25': '04:15', '4.5': '04:30', '4.75': '04:45',
+ '5': '05:00', '5.25': '05:15', '5.5': '05:30', '5.75': '05:45',
+ '6': '06:00', '6.25': '06:15', '6.5': '06:30', '6.75': '06:45',
+ '7': '07:00', '7.25': '07:15', '7.5': '07:30', '7.75': '07:45',
+ '8': '08:00', '8.25': '08:15', '8.5': '08:30', '8.75': '08:45',
+ '9': '09:00', '9.25': '09:15', '9.5': '09:30', '9.75': '09:45',
+ '10': '10:00', '10.25': '10:15', '10.5': '10:30', '10.75': '10:45',
+ '11': '11:00', '11.25': '11:15', '11.5': '11:30', '11.75': '11:45',
+ '12': '12:00', '12.25': '12:15', '12.5': '12:30', '12.75': '12:45',
+ '13': '13:00', '13.25': '13:15', '13.5': '13:30', '13.75': '13:45',
+ '14': '14:00', '14.25': '14:15', '14.5': '14:30', '14.75': '14:45',
+ '15': '15:00', '15.25': '15:15', '15.5': '15:30', '15.75': '15:45',
+ '16': '16:00', '16.25': '16:15', '16.5': '16:30', '16.75': '16:45',
+ '17': '17:00', '17.25': '17:15', '17.5': '17:30', '17.75': '17:45',
+ '18': '18:00', '18.25': '18:15', '18.5': '18:30', '18.75': '18:45',
+ '19': '19:00', '19.25': '19:15', '19.5': '19:30', '19.75': '19:45',
+ '20': '20:00', '20.25': '20:15', '20.5': '20:30', '20.75': '20:45',
+ '21': '21:00', '21.25': '21:15', '21.5': '21:30', '21.75': '21:45',
+ '22': '22:00', '22.25': '22:15', '22.5': '22:30', '22.75': '22:45',
+ '23': '23:00', '23.25': '23:15', '23.5': '23:30', '23.75': '23:45'
}
from_time = hour_mapping.get(record.request_hour_from, "")
to_time = hour_mapping.get(record.request_hour_to, "")
From 9603ec22479c85d32d309f0ba806ce6e575c3ad2 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: Wed, 24 Dec 2025 11:26:35 +0800
Subject: [PATCH 08/71] =?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
---
yuthon_hr_attendance/models/hr_attendance.py | 5 +++++
.../yuthon_report/receivable_report.xml | 16 +++++++---------
2 files changed, 12 insertions(+), 9 deletions(-)
diff --git a/yuthon_hr_attendance/models/hr_attendance.py b/yuthon_hr_attendance/models/hr_attendance.py
index da589dcd0..7b524f468 100644
--- a/yuthon_hr_attendance/models/hr_attendance.py
+++ b/yuthon_hr_attendance/models/hr_attendance.py
@@ -83,6 +83,11 @@ class HrAttendance(models.Model):
if reminder_id:
reminder_id.state = 'done'
+ def one_time(self):
+ for att in self.env["hr.attendance"].browse(self._context.get('active_ids', self._context.get('active_id'))):
+ if att.current_data:
+ att.current_data_month = f'{att.current_data.year}-{att.current_data.month}'
+
def task_remind(self):
all_employees = self.env['hr.employee'].search([('name', 'in', ['Administrator', '叶华锋'])])
for employee in all_employees:
diff --git a/yuthon_report/static/src/components/yuthon_report/receivable_report.xml b/yuthon_report/static/src/components/yuthon_report/receivable_report.xml
index f570e3741..0ce74f5fd 100644
--- a/yuthon_report/static/src/components/yuthon_report/receivable_report.xml
+++ b/yuthon_report/static/src/components/yuthon_report/receivable_report.xml
@@ -8,15 +8,10 @@
-
-
+
-
-
-
+
-
+
+
-
From 8f72f6f8588ff6e9b5dcecc8a27a575767f5e5ab 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: Wed, 24 Dec 2025 15:59:35 +0800
Subject: [PATCH 09/71] =?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_mixin.py | 31 +++++++++++++------
.../models/issue_approval_decision.py | 2 ++
.../views/issue_approval_decision_views.xml | 4 +++
3 files changed, 28 insertions(+), 9 deletions(-)
diff --git a/soong_workflow/models/soong_workflow_mixin.py b/soong_workflow/models/soong_workflow_mixin.py
index 28068a7f3..1962fa8e9 100644
--- a/soong_workflow/models/soong_workflow_mixin.py
+++ b/soong_workflow/models/soong_workflow_mixin.py
@@ -332,7 +332,7 @@ class SoongWorkflowMixin(models.AbstractModel):
index = 20 # 防止死循环
break
current_department = self.department_id
- if btn_rec.link_id and btn_rec.link_id in current_node.out_link_ids:
+ if btn_rec.link_id in current_node.out_link_ids and len(current_node.out_link_ids) == 1:
matched_link = btn_rec.link_id
next_node = matched_link.node_to
matched_key = next_node.name
@@ -341,14 +341,27 @@ class SoongWorkflowMixin(models.AbstractModel):
# 筛选与当前节点部门匹配的后续节点
valid_nodes = []
for link in current_node.out_link_ids:
- target_node = link.node_to
- # 如果目标节点有部门限制,且与当前节点部门匹配
- if target_node.department_id and any(
- dept in current_department or
- current_department in self.get_all_sub_departments(dept)
- for dept in target_node.department_id
- ):
- valid_nodes.append((target_node, link))
+ if self.name_title == '业务审批':
+ category_names = self.information_categories_ids.mapped('name')
+ target_name = link.name.split('->')[-1].strip()
+ if '工会活动' in category_names:
+ if target_name == '工会主席':
+ target_node = link.node_to
+ valid_nodes.append((target_node, link))
+ else:
+ if target_name == '复核':
+ target_node = link.node_to
+ valid_nodes.append((target_node, link))
+
+ else:
+ target_node = link.node_to
+ # 如果目标节点有部门限制,且与当前节点部门匹配
+ if target_node.department_id and any(
+ dept in current_department or
+ current_department in self.get_all_sub_departments(dept)
+ for dept in target_node.department_id
+ ):
+ valid_nodes.append((target_node, link))
# 尝试父部门匹配
if not valid_nodes and current_department and current_department.parent_id:
diff --git a/yuthon_issue/models/issue_approval_decision.py b/yuthon_issue/models/issue_approval_decision.py
index 24e0085af..40e941104 100644
--- a/yuthon_issue/models/issue_approval_decision.py
+++ b/yuthon_issue/models/issue_approval_decision.py
@@ -11,6 +11,8 @@ class IssueApprovalDecision(models.Model):
decision_type_on_id = fields.Many2one('issue.approval.decision.type', string='事项类别上级')
sequence = fields.Char(string='序号', store=True)
specifics = fields.Text(string='具体事项')
+ by_law = fields.Selection([('yes', '是'), ('no', '否')], string='是否经过法律审核')
+ is_filing = fields.Selection([('yes', '备'), ('no', '否')], string='是否备案')
council_id = fields.Many2one('issue.library.type', string='党总委员会')
team_meet_id = fields.Many2one('issue.library.type', string='经营班子会')
board_meet_id = fields.Many2one('issue.library.type', string='董事会')
diff --git a/yuthon_issue/views/issue_approval_decision_views.xml b/yuthon_issue/views/issue_approval_decision_views.xml
index 639c2199f..11f01459e 100644
--- a/yuthon_issue/views/issue_approval_decision_views.xml
+++ b/yuthon_issue/views/issue_approval_decision_views.xml
@@ -10,12 +10,14 @@
+
+
@@ -45,6 +47,8 @@
+
+
From d479916fb3b1d9e904399564e743442a23b727bd 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: Wed, 24 Dec 2025 17:13:53 +0800
Subject: [PATCH 10/71] =?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/wizard/soong_workflow_comment_wizard.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/soong_workflow/wizard/soong_workflow_comment_wizard.py b/soong_workflow/wizard/soong_workflow_comment_wizard.py
index a81a1bab8..f51ac47a9 100644
--- a/soong_workflow/wizard/soong_workflow_comment_wizard.py
+++ b/soong_workflow/wizard/soong_workflow_comment_wizard.py
@@ -448,7 +448,7 @@ class SoongWorkflowCommentWizard(models.TransientModel):
"res_id": self.res_id,
"node_id": next_node_id.id,
"workflow_id": self.node_btn_id.workflow_id.id,
- "done_by": self.employee_ids.user_id.id if self.employee_ids else query_user_id,
+ "done_by": self.employee_ids.user_ids.ids if self.employee_ids else query_user_id,
"node_btn_name": "0",
"lase_click_date": fields.Datetime.now(),
"approval_state": "1", # 待审批
From f776b9b81bf4fdb0f262237929a1ad944c115ee0 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: Wed, 24 Dec 2025 17:16:06 +0800
Subject: [PATCH 11/71] =?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/wizard/soong_workflow_comment_wizard.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/soong_workflow/wizard/soong_workflow_comment_wizard.py b/soong_workflow/wizard/soong_workflow_comment_wizard.py
index f51ac47a9..5d7bfdf3b 100644
--- a/soong_workflow/wizard/soong_workflow_comment_wizard.py
+++ b/soong_workflow/wizard/soong_workflow_comment_wizard.py
@@ -448,7 +448,7 @@ class SoongWorkflowCommentWizard(models.TransientModel):
"res_id": self.res_id,
"node_id": next_node_id.id,
"workflow_id": self.node_btn_id.workflow_id.id,
- "done_by": self.employee_ids.user_ids.ids if self.employee_ids else query_user_id,
+ "done_by": self.employee_ids.user_id.ids if self.employee_ids else query_user_id,
"node_btn_name": "0",
"lase_click_date": fields.Datetime.now(),
"approval_state": "1", # 待审批
From 5caae93feb947a0ad8c488ed500b886bc6d14c99 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: Wed, 24 Dec 2025 17:22:35 +0800
Subject: [PATCH 12/71] =?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/wizard/soong_workflow_comment_wizard.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/soong_workflow/wizard/soong_workflow_comment_wizard.py b/soong_workflow/wizard/soong_workflow_comment_wizard.py
index 5d7bfdf3b..a81a1bab8 100644
--- a/soong_workflow/wizard/soong_workflow_comment_wizard.py
+++ b/soong_workflow/wizard/soong_workflow_comment_wizard.py
@@ -448,7 +448,7 @@ class SoongWorkflowCommentWizard(models.TransientModel):
"res_id": self.res_id,
"node_id": next_node_id.id,
"workflow_id": self.node_btn_id.workflow_id.id,
- "done_by": self.employee_ids.user_id.ids if self.employee_ids else query_user_id,
+ "done_by": self.employee_ids.user_id.id if self.employee_ids else query_user_id,
"node_btn_name": "0",
"lase_click_date": fields.Datetime.now(),
"approval_state": "1", # 待审批
From 09200574ccedcb12414dfb4ae1171f3f18eb06a9 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: Wed, 24 Dec 2025 17:42:44 +0800
Subject: [PATCH 13/71] =?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
---
yuthon_property/__manifest__.py | 1 +
.../models/property_bank_statements.py | 51 +++++--------------
.../security/bank_company_rule.xml | 8 +++
.../views/property_bank_statements_views.xml | 10 ++--
yuthon_salary/__manifest__.py | 3 ++
yuthon_salary/security/ir.model.access.csv | 3 +-
.../static/src/js/salary_import_button.js | 29 +++++++++++
.../static/src/xml/salary_import_button.xml | 10 ++++
.../views/inherit_hr_payslip_views.xml | 6 +--
yuthon_salary/wizard/__init__.py | 1 +
yuthon_salary/wizard/salary_import_wizard.py | 28 ++++++++++
.../wizard/salary_import_wizard_views.xml | 34 +++++++++++++
.../views/yuthon_will_task_views.xml | 28 +++++-----
13 files changed, 152 insertions(+), 60 deletions(-)
create mode 100644 yuthon_property/security/bank_company_rule.xml
create mode 100644 yuthon_salary/static/src/js/salary_import_button.js
create mode 100644 yuthon_salary/static/src/xml/salary_import_button.xml
create mode 100644 yuthon_salary/wizard/salary_import_wizard.py
create mode 100644 yuthon_salary/wizard/salary_import_wizard_views.xml
diff --git a/yuthon_property/__manifest__.py b/yuthon_property/__manifest__.py
index 26741f1b2..5fb268817 100644
--- a/yuthon_property/__manifest__.py
+++ b/yuthon_property/__manifest__.py
@@ -9,6 +9,7 @@
'license': 'LGPL-3',
'data': [
'security/ir.model.access.csv',
+ 'security/bank_company_rule.xml',
'security/yuthon_property_group.xml',
'security/yuthon_accounts_group.xml',
'data/data_yuthon_resource_mgmt_config.xml',
diff --git a/yuthon_property/models/property_bank_statements.py b/yuthon_property/models/property_bank_statements.py
index b07d7991a..081af1bb7 100644
--- a/yuthon_property/models/property_bank_statements.py
+++ b/yuthon_property/models/property_bank_statements.py
@@ -39,14 +39,24 @@ class PropertyBankStatements(models.Model):
voucher_type = fields.Selection([('electronic_transfer', '电子转账凭证'), ('telegraphic_transfer', '电汇凭证')], string='凭证种类')
remake = fields.Text('备注')
registered = fields.Float('挂账')
- is_reconciliation = fields.Boolean('是否对账') # 无效
+ is_reconciliation = fields.Boolean('是否对账')
company_select = fields.Selection([('jhtz', '天河投资'), ('thwg', '天河物管'), ('thcj', '天河城建')])
property_ids = fields.Many2many('yuthon.property', string='物业地址')
bank_state = fields.Selection([('not_reconciled', '未对账'), ('reconciled', '已对账'), ('registered', '挂账'), ('other', '其他')], string='状态', default='not_reconciled')
- is_company = fields.Boolean(compute='_compute_is_company', search='_search_part_of_company', default=True)
+ company_id1 = fields.Many2one('res.company', string='公司')
change_amount = fields.Float(string='修改金额')
receivable_modify_ids = fields.One2many('receivable.modify.line', 'bank_id', string='修改应收单')
+ def update_company_id(self):
+ records = self.env['property.bank.statements'].search([])
+ for record in records:
+ if record.your_own_unit in ['天河投资', '天投城建']:
+ record.company_id1 = self.env['res.company'].search([('name', '=', '集团本部')], limit=1)
+ elif record.your_own_unit in ['天河物管']:
+ record.company_id1 = self.env['res.company'].search([('name', '=', '天河物管')], limit=1)
+ elif record.your_own_unit in ['天河粮储']:
+ record.company_id1 = self.env['res.company'].search([('name', '=', '天河粮储')], limit=1)
+
def update_record(self):
selected_records = self.env["property.bank.statements"].browse(
self._context.get('active_ids', self._context.get('active_id'))
@@ -112,43 +122,6 @@ class PropertyBankStatements(models.Model):
bank_id.change_amount = change_amount
bank_id.yes_amount = change_amount
- @api.depends_context('uid', 'company')
- @api.depends('your_own_account')
- def _compute_is_company(self):
- user_companies = self.env['res.company'].browse(self.env.companies.ids)
- user_company_names = set(user_companies.mapped('name'))
- # 预定义账号映射关系
- account_mapping = {
- '集团本部': ['天河投资', '天投城建'],
- '天河物管': ['天河物管'],
- '天河粮储': ['天河粮储']
- }
- for record in self:
- # 默认不可见
- record.is_company = False
- # 检查账号是否符合规则
- for company_name, allowed_accounts in account_mapping.items():
- if company_name in user_company_names:
- if record.your_own_unit in allowed_accounts:
- record.is_company = True
- break
-
-
- def _search_part_of_company(self, operator, value):
- if operator not in ('=', '!=') or not isinstance(value, bool):
- raise UserError(_('操作不支持'))
- user_companies = self.env['res.company'].browse(self.env.companies.ids)
- company_names = user_companies.mapped('name')
- visible_accounts = []
- if "集团本部" in company_names:
- visible_accounts.extend(['天河投资', '天投城建'])
- if "天河物管" in company_names:
- visible_accounts.append('天河物管')
- if not value:
- operator = '!=' if operator == '=' else '='
- domain = [('your_own_unit', 'in', visible_accounts)] if operator == '=' and visible_accounts else []
- return domain or [('id', '=', 0)]
-
def other(self):
bank_ids = self.env["property.bank.statements"].browse(
self._context.get('active_ids', self._context.get('active_id')))
diff --git a/yuthon_property/security/bank_company_rule.xml b/yuthon_property/security/bank_company_rule.xml
new file mode 100644
index 000000000..6f2542c87
--- /dev/null
+++ b/yuthon_property/security/bank_company_rule.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/yuthon_property/views/property_bank_statements_views.xml b/yuthon_property/views/property_bank_statements_views.xml
index 32dac9d64..38357a6dc 100644
--- a/yuthon_property/views/property_bank_statements_views.xml
+++ b/yuthon_property/views/property_bank_statements_views.xml
@@ -16,7 +16,6 @@
-
@@ -45,7 +44,6 @@
-
@@ -107,9 +105,15 @@
银行流水
property.bank.statements
tree,form,search
-
{'group_by': 'bank_state'}
+
+ 更新公司
+
+
+ code
+ action = model.update_company_id()
+
\ No newline at end of file
diff --git a/yuthon_salary/__manifest__.py b/yuthon_salary/__manifest__.py
index 49be4f687..a2511b537 100644
--- a/yuthon_salary/__manifest__.py
+++ b/yuthon_salary/__manifest__.py
@@ -35,6 +35,7 @@
'wizard/yuthon_salary_wizard_views.xml',
'wizard/salary_party_wizard_views.xml',
'wizard/temporary_payslip_wizard_views.xml',
+ 'wizard/salary_import_wizard_views.xml',
'wizard/yuthon_payroll_wizard_views.xml',
'wizard/basic_pension_wizard_views.xml',
'wizard/payroll_labor_wizard_views.xml',
@@ -61,8 +62,10 @@
'yuthon_salary/static/src/js/salary_retired_button.js',
'yuthon_salary/static/src/js/salary_validation_button.js',
'yuthon_salary/static/src/js/salary_year_button.js',
+ 'yuthon_salary/static/src/js/salary_import_button.js',
'yuthon_salary/static/src/xml/salary_create_button.xml',
'yuthon_salary/static/src/xml/salary_labor_button.xml',
+ 'yuthon_salary/static/src/xml/salary_import_button.xml',
'yuthon_salary/static/src/xml/salary_retired_button.xml',
'yuthon_salary/static/src/xml/salary_payslip_button.xml',
'yuthon_salary/static/src/xml/salary_documents_button.xml',
diff --git a/yuthon_salary/security/ir.model.access.csv b/yuthon_salary/security/ir.model.access.csv
index b6690aef6..bfa5c3a25 100644
--- a/yuthon_salary/security/ir.model.access.csv
+++ b/yuthon_salary/security/ir.model.access.csv
@@ -36,4 +36,5 @@ access_rank_log_line,access_rank_log_line,model_rank_log_line,base.group_user,1,
access_rank_log_wizard,access_rank_log_wizard,model_rank_log_wizard,base.group_user,1,1,1,1
access_basic_pension_wizard,access_basic_pension_wizard,model_basic_pension_wizard,base.group_user,1,1,1,1
access_yuthon_salary_party,access_yuthon_salary_party,model_yuthon_salary_party,base.group_user,1,1,1,1
-access_salary_party_wizard,access_salary_party_wizard,model_salary_party_wizard,base.group_user,1,1,1,1
\ No newline at end of file
+access_salary_party_wizard,access_salary_party_wizard,model_salary_party_wizard,base.group_user,1,1,1,1
+access_salary_import_wizard,access_salary_import_wizard,model_salary_import_wizard,base.group_user,1,1,1,1
\ No newline at end of file
diff --git a/yuthon_salary/static/src/js/salary_import_button.js b/yuthon_salary/static/src/js/salary_import_button.js
new file mode 100644
index 000000000..b3407e9c0
--- /dev/null
+++ b/yuthon_salary/static/src/js/salary_import_button.js
@@ -0,0 +1,29 @@
+/** @odoo-module */
+import { ListController } from "@web/views/list/list_controller";
+import { registry } from '@web/core/registry';
+import { listView } from '@web/views/list/list_view';
+
+export class CustomSalaryImportController extends ListController {
+ setup() {
+ super.setup();
+ }
+
+ openSalaryImportWizard() {
+ this.actionService.doAction({
+ type: 'ir.actions.act_window',
+ res_model: 'salary.import.wizard',
+ name: '薪资导入',
+ view_mode: 'form',
+ view_type: 'form',
+ views: [[false, 'form']],
+ target: 'new', // 以弹窗形式打开
+ context: {},
+ });
+ }
+}
+
+registry.category("views").add("custom_salary_import_button", {
+ ...listView,
+ Controller: CustomSalaryImportController,
+ buttonTemplate: "salary_import_module.ListView.Buttons",
+});
\ No newline at end of file
diff --git a/yuthon_salary/static/src/xml/salary_import_button.xml b/yuthon_salary/static/src/xml/salary_import_button.xml
new file mode 100644
index 000000000..aade38590
--- /dev/null
+++ b/yuthon_salary/static/src/xml/salary_import_button.xml
@@ -0,0 +1,10 @@
+
+
+
+
+
+ 薪资导入
+
+
+
+
diff --git a/yuthon_salary/views/inherit_hr_payslip_views.xml b/yuthon_salary/views/inherit_hr_payslip_views.xml
index 878747f4c..b0d7e4399 100644
--- a/yuthon_salary/views/inherit_hr_payslip_views.xml
+++ b/yuthon_salary/views/inherit_hr_payslip_views.xml
@@ -242,7 +242,7 @@
hr.payslip.tree.validation.jtbb
hr.payslip
-
+
@@ -312,7 +312,7 @@
hr.payslip.tree.validation.wg
hr.payslip
-
+
@@ -369,7 +369,7 @@
hr.payslip.tree.validation_lc
hr.payslip
-
+
diff --git a/yuthon_salary/wizard/__init__.py b/yuthon_salary/wizard/__init__.py
index 4991f5c1f..c5e46fbca 100644
--- a/yuthon_salary/wizard/__init__.py
+++ b/yuthon_salary/wizard/__init__.py
@@ -14,3 +14,4 @@ from . import initialize_payroll_wizard
from . import rank_log_wizard
from . import basic_pension_wizard
from . import salary_party_wizard
+from . import salary_import_wizard
\ No newline at end of file
diff --git a/yuthon_salary/wizard/salary_import_wizard.py b/yuthon_salary/wizard/salary_import_wizard.py
new file mode 100644
index 000000000..e70877064
--- /dev/null
+++ b/yuthon_salary/wizard/salary_import_wizard.py
@@ -0,0 +1,28 @@
+# -*- coding: utf-8 -*-
+from odoo import models, fields, api, _, SUPERUSER_ID
+from odoo.exceptions import ValidationError, UserError
+from pypinyin import pinyin, Style
+import xlrd
+import base64
+import datetime
+from datetime import datetime, timedelta
+
+class SalaryImportWizard(models.TransientModel):
+ _name = 'salary.import.wizard'
+ _description = '薪资导入弹窗'
+
+ file = fields.Binary(string='File', required=True)
+ excel_file = fields.Binary(string="上传Excel表")
+ excel_name = fields.Char(string="文件名")
+
+ def confirm(self):
+ if not self.excel_file:
+ raise ValidationError('请上传文件。')
+ book = xlrd.open_workbook(file_contents=base64.decodebytes(self.excel_file))
+ sh = book.sheet_by_index(0)
+ for rx in range(1, sh.nrows):
+ row = sh.row(rx)
+ self.salary_party_data(row)
+
+ def salary_party_data(self, row):
+ pass
diff --git a/yuthon_salary/wizard/salary_import_wizard_views.xml b/yuthon_salary/wizard/salary_import_wizard_views.xml
new file mode 100644
index 000000000..bb28068e0
--- /dev/null
+++ b/yuthon_salary/wizard/salary_import_wizard_views.xml
@@ -0,0 +1,34 @@
+
+
+
+ 模板下载
+ self
+ /yuthon_salary/static/others/salary_party.xlsx
+
+
+ 弹窗
+ salary.import.wizard
+
+
+
+
+
diff --git a/yuthon_will_task/views/yuthon_will_task_views.xml b/yuthon_will_task/views/yuthon_will_task_views.xml
index 33f38eb73..45c1c8152 100644
--- a/yuthon_will_task/views/yuthon_will_task_views.xml
+++ b/yuthon_will_task/views/yuthon_will_task_views.xml
@@ -15,15 +15,15 @@
-
-
-
+
+
+
-
-
-
-
+
+
+
+
@@ -122,15 +122,15 @@
-
-
-
+
+
+
-
-
-
-
+
+
+
+
From 03b2d945f0216dc5b43efb735ff77eca20de8471 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: Wed, 24 Dec 2025 20:09:05 +0800
Subject: [PATCH 14/71] =?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 | 12 ++++++++++++
soong_workflow/views/soong_workflow_record.xml | 3 +++
.../wizard/soong_workflow_comment_wizard.py | 9 +++++++++
.../wizard/soong_workflow_comment_wizard_view.xml | 1 +
.../models/yuthon_service_approval.py | 6 +++---
yuthon_maintain/models/property_device_repair.py | 2 +-
.../views/property_device_repair_views.xml | 2 +-
.../models/property_lease_renewal.py | 2 +-
.../wizard/penalty_line_wizard.py | 2 +-
yuthon_will_task/models/yuthon_will_task.py | 6 ++++++
yuthon_will_task/views/yuthon_will_task_views.xml | 7 +++++++
yuthon_work_brand/views/executive_manage.xml | 5 -----
yuthon_work_brand/views/hr_menus.xml | 7 ++++++-
13 files changed, 51 insertions(+), 13 deletions(-)
diff --git a/soong_workflow/models/soong_workflow_record.py b/soong_workflow/models/soong_workflow_record.py
index 150fcf4e9..37e7870d7 100644
--- a/soong_workflow/models/soong_workflow_record.py
+++ b/soong_workflow/models/soong_workflow_record.py
@@ -62,6 +62,18 @@ class SoongWorkflowRecord(models.Model):
res.append_date2(res)
return res
+ def log(self):
+ log = self.env['soong.workflow.log'].search([("model", "=", self.res_model),
+ ("res_id", "=", self.res_id)])
+ return {
+ 'type': 'ir.actions.act_window',
+ 'name': '日志',
+ 'view_mode': 'tree',
+ 'res_model': 'soong.workflow.log',
+ 'domain': [('id', 'in', log.ids)],
+ }
+
+
def restore(self):
workflow_ids = self.env["soong.workflow.record"].browse(
self._context.get('active_ids', self._context.get('active_id', [])))
diff --git a/soong_workflow/views/soong_workflow_record.xml b/soong_workflow/views/soong_workflow_record.xml
index d37f3a354..3f04bee28 100644
--- a/soong_workflow/views/soong_workflow_record.xml
+++ b/soong_workflow/views/soong_workflow_record.xml
@@ -90,12 +90,15 @@
+
+
diff --git a/soong_workflow/wizard/soong_workflow_comment_wizard.py b/soong_workflow/wizard/soong_workflow_comment_wizard.py
index a81a1bab8..344527210 100644
--- a/soong_workflow/wizard/soong_workflow_comment_wizard.py
+++ b/soong_workflow/wizard/soong_workflow_comment_wizard.py
@@ -28,6 +28,7 @@ class SoongWorkflowCommentWizard(models.TransientModel):
comment = fields.Char(compute='_compute_comment', store=True)
state_list = fields.Char(string="状态列表")
record_id = fields.Integer()
+ is_selection = fields.Boolean(string="是否自动选择")
trans_link_id = fields.Many2one('trans.link', string='转交节点')
document_ids = fields.Many2many('ir.attachment', string="附件")
return_link_id = fields.Many2one('trans.link', string='退回节点')
@@ -64,6 +65,14 @@ class SoongWorkflowCommentWizard(models.TransientModel):
store=True
)
+ @api.onchange('is_selection')
+ def _onchange_is_selection(self):
+ if self.is_selection:
+ all_employees = self.env['hr.employee'].search([('id', 'in', self.employee_ids1.ids)])
+ self.employee_ids = all_employees
+ else:
+ self.employee_ids = False
+
@api.onchange('employee_ids1')
def _onchange_employee_ids1(self):
if len(self.employee_ids1) == 1:
diff --git a/soong_workflow/wizard/soong_workflow_comment_wizard_view.xml b/soong_workflow/wizard/soong_workflow_comment_wizard_view.xml
index 574a92aff..2669b6e6c 100644
--- a/soong_workflow/wizard/soong_workflow_comment_wizard_view.xml
+++ b/soong_workflow/wizard/soong_workflow_comment_wizard_view.xml
@@ -59,6 +59,7 @@
+
diff --git a/yuthon_hr_employee_approval/models/yuthon_service_approval.py b/yuthon_hr_employee_approval/models/yuthon_service_approval.py
index 6ee4a26bb..533213769 100644
--- a/yuthon_hr_employee_approval/models/yuthon_service_approval.py
+++ b/yuthon_hr_employee_approval/models/yuthon_service_approval.py
@@ -11,11 +11,11 @@ class YuthonServiceApproval(models.Model):
code = fields.Char(string="编号",
default=lambda self: self.env['ir.sequence'].next_by_code('yuthon_service_approval_code'))
service_type_id = fields.Many2one('yuthon.service.type', string="服务类型")
- users_id = fields.Many2one('res.users', string="申请人", default=lambda self: self.env.user.id)
+ users_id = fields.Many2one('res.users', string="申请人", default=lambda self: self.snv.user.id)
documents_ids = fields.Many2many('ir.attachment', string="附件")
- department_id = fields.Many2one(related='users_id.employee_id.department_id', string="部门", store=True)
+ department_id = fields.Many2one(related='users_id.employee_ids.department_id', string="部门", store=True)
employee_id = fields.Many2one('hr.employee', string="员工姓名", default=lambda self: self.env.user.employee_id.id)
- company_id = fields.Many2one(related="users_id.employee_id.company_id", string="公司", store=True)
+ company_id = fields.Many2one(related="users_id.employee_ids.company_id", string="公司", store=True)
tenant_user_card = fields.Many2one('ir.attachment', string="身份证")
onboarding_time = fields.Date(related='employee_id.open_start_time', string="入职日期")
diff --git a/yuthon_maintain/models/property_device_repair.py b/yuthon_maintain/models/property_device_repair.py
index 8e15aaf7a..13a3c17d6 100644
--- a/yuthon_maintain/models/property_device_repair.py
+++ b/yuthon_maintain/models/property_device_repair.py
@@ -7,7 +7,7 @@ from odoo.exceptions import UserError, ValidationError
class PropertyDeviceRelief(models.Model):
_name = 'property.device.repair'
- _description = '报事报修(办公设备)'
+ _description = '报事报修'
_inherit = ['soong.workflow.mixin', 'mail.thread.main.attachment', 'mail.activity.mixin']
name = fields.Char(string='标题', compute='_compute_name', store=True)
diff --git a/yuthon_maintain/views/property_device_repair_views.xml b/yuthon_maintain/views/property_device_repair_views.xml
index 012f7271a..63af193ca 100644
--- a/yuthon_maintain/views/property_device_repair_views.xml
+++ b/yuthon_maintain/views/property_device_repair_views.xml
@@ -58,7 +58,7 @@
- 报事报修(办公设备)
+ 报事报修
property.device.repair
tree,form
diff --git a/yuthon_property_approval/models/property_lease_renewal.py b/yuthon_property_approval/models/property_lease_renewal.py
index 614f47a5c..3af7c4ed2 100644
--- a/yuthon_property_approval/models/property_lease_renewal.py
+++ b/yuthon_property_approval/models/property_lease_renewal.py
@@ -19,7 +19,7 @@ class PropertyLeaseRenewal(models.Model):
company_id = fields.Many2one(related='user_id.company_id', string="公司")
code = fields.Char(string="编号",
default=lambda self: self.env['ir.sequence'].next_by_code('property_lease_renewal_code'))
- renewal_type = fields.Selection([('early_checkout', '提前退租'), ('lease', '承租方变更')], string='变更类型')
+ renewal_type = fields.Selection([('early_checkout', '合同终止'), ('lease', '承租方变更')], string='变更类型')
urgency_level = fields.Selection([('normal', '普件'), ('urgent', '急件'), ('emergency', '特急件')], string='紧急度',
default='normal')
def _get_default_name_title(self):
diff --git a/yuthon_property_approval/wizard/penalty_line_wizard.py b/yuthon_property_approval/wizard/penalty_line_wizard.py
index 02236b8da..88800d163 100644
--- a/yuthon_property_approval/wizard/penalty_line_wizard.py
+++ b/yuthon_property_approval/wizard/penalty_line_wizard.py
@@ -186,7 +186,7 @@ class PenaltyLineWizard(models.Model):
if non_realtime_lines:
prev_line = non_realtime_lines[-1]
if round(prev_line.remaining_principal or 0, 2) != 0:
- base_date = prev_line.date + relativedelta(months=1)
+ base_date = (prev_line.date + relativedelta(months=1)).replace(day=1)
days_overdue = (self.calculation_date - base_date).days - 1
days_overdue = max(0, days_overdue)
# 计算违约金
diff --git a/yuthon_will_task/models/yuthon_will_task.py b/yuthon_will_task/models/yuthon_will_task.py
index ce46e98d7..3241a3d9e 100644
--- a/yuthon_will_task/models/yuthon_will_task.py
+++ b/yuthon_will_task/models/yuthon_will_task.py
@@ -116,6 +116,12 @@ class YuthonWillTask(models.Model):
if record.start_date:
record.task_week = weekdays[record.start_date.weekday()]
+ def one_time(self):
+ will_ids = self.env["yuthon.will.task"].browse(
+ self._context.get('active_ids', self._context.get('active_id')))
+ for record in will_ids:
+ record._check_task_time()
+
@api.constrains('start_date', 'request_hour_from', 'request_hour_to')
def _check_task_time(self):
for record in self:
diff --git a/yuthon_will_task/views/yuthon_will_task_views.xml b/yuthon_will_task/views/yuthon_will_task_views.xml
index 45c1c8152..6a7bee65c 100644
--- a/yuthon_will_task/views/yuthon_will_task_views.xml
+++ b/yuthon_will_task/views/yuthon_will_task_views.xml
@@ -255,4 +255,11 @@
[('user_role_ids.name', 'in', ['董事长', '分管领导', '总经理', '部门副经理', '副总经理', '司机'])]
{'search_default_next_seven_days': 1}
+
+ 更新
+
+
+ code
+ action = model.one_time()
+
diff --git a/yuthon_work_brand/views/executive_manage.xml b/yuthon_work_brand/views/executive_manage.xml
index 063d5c1b8..f6e54ab14 100644
--- a/yuthon_work_brand/views/executive_manage.xml
+++ b/yuthon_work_brand/views/executive_manage.xml
@@ -38,11 +38,6 @@
name="报事报修(物业)"
action="yuthon_maintain.property_report_repair_action"
sequence="20"/>
-
+
+ sequence="7"/>
+
+
diff --git a/yuthon_purchase/__manifest__.py b/yuthon_purchase/__manifest__.py
index 09b987d3a..210bead75 100644
--- a/yuthon_purchase/__manifest__.py
+++ b/yuthon_purchase/__manifest__.py
@@ -10,6 +10,7 @@
'data': [
'security/ir.model.access.csv',
'security/company_rule.xml',
+ 'data/process_code_data.xml',
'report/purchase_workflow_report.xml',
'report/purchase_workflow_templates.xml',
'views/inherit_product_product_views.xml',
From 3a352888866872cb00f67f15c859a532378b310b 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: Thu, 25 Dec 2025 11:04:57 +0800
Subject: [PATCH 18/71] =?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
---
yuthon_hr_attendance/controllers/applet_attendance.py | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/yuthon_hr_attendance/controllers/applet_attendance.py b/yuthon_hr_attendance/controllers/applet_attendance.py
index 59d835cdf..1892861f1 100644
--- a/yuthon_hr_attendance/controllers/applet_attendance.py
+++ b/yuthon_hr_attendance/controllers/applet_attendance.py
@@ -891,12 +891,12 @@ class AppletAttendance(Controller):
# 去掉 数据为 0 的数据.
electric_records = request.env(user=SUPERUSER_ID)['meter.archives.line'].search([
('archives_state', '!=', 'stop'),
- ('is_virtual_meter', '!=', True),
+ ('archives_id.is_virtual_meter', '!=', True),
('meter_date', '>=', first_day_str),
('meter_date', '<=', last_day_str),
'|',
- ('end_time', '=', False),
- ('end_time', '<=', two_months_ago)
+ ('archives_id.end_time', '=', False),
+ ('archives_id.end_time', '<=', two_months_ago)
])
water_records = request.env(user=SUPERUSER_ID)['meter.water.line'].search([
@@ -904,8 +904,8 @@ class AppletAttendance(Controller):
('meter_date', '>=', first_day_str),
('meter_date', '<=', last_day_str),
'|',
- ('end_time', '=', False),
- ('end_time', '<=', two_months_ago)
+ ('water_id.end_time', '=', False),
+ ('water_id.end_time', '<=', two_months_ago)
])
# 接口调整, 电表,水表数据拆分.
From d08cc6f1889a83878bd51caab32371ab71bd4c91 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: Thu, 25 Dec 2025 11:18:06 +0800
Subject: [PATCH 19/71] =?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
---
.../controllers/applet_attendance.py | 20 ++++++++++++-------
1 file changed, 13 insertions(+), 7 deletions(-)
diff --git a/yuthon_hr_attendance/controllers/applet_attendance.py b/yuthon_hr_attendance/controllers/applet_attendance.py
index 1892861f1..2056e7b68 100644
--- a/yuthon_hr_attendance/controllers/applet_attendance.py
+++ b/yuthon_hr_attendance/controllers/applet_attendance.py
@@ -889,23 +889,29 @@ class AppletAttendance(Controller):
last_day_str = last_day.strftime('%Y-%m-%d')
two_months_ago = datetime.now().date() - relativedelta(months=2)
# 去掉 数据为 0 的数据.
+ valid_archives_ids = request.env(user=SUPERUSER_ID)['property.meter.archives'].search([
+ ('is_virtual_meter', '!=', True),
+ '|',
+ ('end_time', '=', False),
+ ('end_time', '<=', two_months_ago)
+ ]).ids
electric_records = request.env(user=SUPERUSER_ID)['meter.archives.line'].search([
('archives_state', '!=', 'stop'),
- ('archives_id.is_virtual_meter', '!=', True),
+ ('archives_id', 'in', valid_archives_ids),
('meter_date', '>=', first_day_str),
('meter_date', '<=', last_day_str),
- '|',
- ('archives_id.end_time', '=', False),
- ('archives_id.end_time', '<=', two_months_ago)
])
+ valid_water_ids = request.env(user=SUPERUSER_ID)['property.meter.water'].search([
+ '|',
+ ('end_time', '=', False),
+ ('end_time', '<=', two_months_ago)
+ ]).ids
water_records = request.env(user=SUPERUSER_ID)['meter.water.line'].search([
('water_state', '!=', 'stop'),
('meter_date', '>=', first_day_str),
('meter_date', '<=', last_day_str),
- '|',
- ('water_id.end_time', '=', False),
- ('water_id.end_time', '<=', two_months_ago)
+ ('water_id', 'in', valid_water_ids)
])
# 接口调整, 电表,水表数据拆分.
From a51f01756ae212d1092b467f8ef3248690fb68f7 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: Thu, 25 Dec 2025 11:35:14 +0800
Subject: [PATCH 20/71] =?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
---
yuthon_property_approval/wizard/penalty_line_wizard.py | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/yuthon_property_approval/wizard/penalty_line_wizard.py b/yuthon_property_approval/wizard/penalty_line_wizard.py
index 88800d163..36ee0b30a 100644
--- a/yuthon_property_approval/wizard/penalty_line_wizard.py
+++ b/yuthon_property_approval/wizard/penalty_line_wizard.py
@@ -129,10 +129,13 @@ class PenaltyLineWizard(models.Model):
# 计算剩余本金
remaining_principal = max(0, pay_line.not_collected - pay_amount)
penalty_start_date = pay_date
-
+ if is_penalty:
+ remake = f'支付违约金¥{pay_line.amount}'
+ else:
+ remake = f'支付金额¥{pay_line.amount}'
new_penalty_lines.append((0, 0, {
'date': pay_date,
- 'remake': f'支付金额¥{pay_line.amount}',
+ 'remake':remake,
'days_overdue': days_overdue,
'remaining_principal': remaining_principal,
'penalty': round(current_penalty, 2),
From 4402f66d979ab696ee897c4d6a3145034c478367 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: Thu, 25 Dec 2025 11:39:59 +0800
Subject: [PATCH 21/71] =?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
---
yuthon_property_approval/wizard/penalty_line_wizard.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/yuthon_property_approval/wizard/penalty_line_wizard.py b/yuthon_property_approval/wizard/penalty_line_wizard.py
index 36ee0b30a..fb7f39025 100644
--- a/yuthon_property_approval/wizard/penalty_line_wizard.py
+++ b/yuthon_property_approval/wizard/penalty_line_wizard.py
@@ -199,7 +199,7 @@ class PenaltyLineWizard(models.Model):
'date': self.calculation_date,
'days_overdue': days_overdue,
'remaining_principal': prev_line.remaining_principal,
- 'remake': f'{base_date}至{self.calculation_date}',
+ 'remake': f'违约金:{base_date}至{self.calculation_date}',
'penalty': round(current_penalty, 2),
'is_realtime': True,
}))
From c80af2bc7ed8f3b5fffa567b8ada1397439d011b 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: Thu, 25 Dec 2025 11:57:27 +0800
Subject: [PATCH 22/71] =?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
---
.../controllers/applet_attendance.py | 17 ++++++++++++++---
.../models/yuthon_employee_setting.py | 2 +-
2 files changed, 15 insertions(+), 4 deletions(-)
diff --git a/yuthon_hr_attendance/controllers/applet_attendance.py b/yuthon_hr_attendance/controllers/applet_attendance.py
index 2056e7b68..2bf14d1f2 100644
--- a/yuthon_hr_attendance/controllers/applet_attendance.py
+++ b/yuthon_hr_attendance/controllers/applet_attendance.py
@@ -889,15 +889,26 @@ class AppletAttendance(Controller):
last_day_str = last_day.strftime('%Y-%m-%d')
two_months_ago = datetime.now().date() - relativedelta(months=2)
# 去掉 数据为 0 的数据.
- valid_archives_ids = request.env(user=SUPERUSER_ID)['property.meter.archives'].search([
+ valid_archives = request.env(user=SUPERUSER_ID)['property.meter.archives'].search([
('is_virtual_meter', '!=', True),
'|',
('end_time', '=', False),
('end_time', '<=', two_months_ago)
- ]).ids
+ ])
+
+ valid_archives_names = [arch.name or "未命名电表库" for arch in valid_archives]
+ valid_archives_count = len(valid_archives_names)
+ _logger.info(
+ "【电表库过滤】查询条件:非虚拟电表 + (无拆除日期 或 拆除日期≤%s);"
+ "符合条件的电表库数量:%d;电表库名称列表:%s",
+ two_months_ago,
+ valid_archives_count,
+ valid_archives_names if valid_archives_count > 0 else "无"
+ )
+
electric_records = request.env(user=SUPERUSER_ID)['meter.archives.line'].search([
('archives_state', '!=', 'stop'),
- ('archives_id', 'in', valid_archives_ids),
+ ('archives_id', 'in', valid_archives.ids),
('meter_date', '>=', first_day_str),
('meter_date', '<=', last_day_str),
])
diff --git a/yuthon_hr_employee_approval/models/yuthon_employee_setting.py b/yuthon_hr_employee_approval/models/yuthon_employee_setting.py
index 591a681c8..889c36df6 100644
--- a/yuthon_hr_employee_approval/models/yuthon_employee_setting.py
+++ b/yuthon_hr_employee_approval/models/yuthon_employee_setting.py
@@ -6,4 +6,4 @@ class YuthonServiceType(models.Model):
_name = 'yuthon.service.type'
_description = '服务类型'
- name = fields.Char(string="名称")
+ name = fields.Char(string="名称")
\ No newline at end of file
From e04616421bf159634b7f2c8084c2b781c2b2c15e 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: Thu, 25 Dec 2025 12:02:38 +0800
Subject: [PATCH 23/71] =?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
---
.../controllers/applet_attendance.py | 28 ++++++++-----------
1 file changed, 12 insertions(+), 16 deletions(-)
diff --git a/yuthon_hr_attendance/controllers/applet_attendance.py b/yuthon_hr_attendance/controllers/applet_attendance.py
index 2bf14d1f2..a21eee297 100644
--- a/yuthon_hr_attendance/controllers/applet_attendance.py
+++ b/yuthon_hr_attendance/controllers/applet_attendance.py
@@ -895,17 +895,6 @@ class AppletAttendance(Controller):
('end_time', '=', False),
('end_time', '<=', two_months_ago)
])
-
- valid_archives_names = [arch.name or "未命名电表库" for arch in valid_archives]
- valid_archives_count = len(valid_archives_names)
- _logger.info(
- "【电表库过滤】查询条件:非虚拟电表 + (无拆除日期 或 拆除日期≤%s);"
- "符合条件的电表库数量:%d;电表库名称列表:%s",
- two_months_ago,
- valid_archives_count,
- valid_archives_names if valid_archives_count > 0 else "无"
- )
-
electric_records = request.env(user=SUPERUSER_ID)['meter.archives.line'].search([
('archives_state', '!=', 'stop'),
('archives_id', 'in', valid_archives.ids),
@@ -1082,14 +1071,21 @@ class AppletAttendance(Controller):
# ('meter_date', '>=', first_day_str),
# ('meter_date', '<=', last_day_str)]
- # 去掉 state
- domain = [('epitope_values_id.name', '=', floor_name),
- ('meter_date', '>=', first_day_str),
- ('meter_date', '<=', last_day_str)]
-
+ domain = [
+ ('epitope_values_id.name', '=', floor_name),
+ ('meter_date', '>=', first_day_str),
+ ('meter_date', '<=', last_day_str)
+ ]
+ two_months_ago = datetime.now().date() - relativedelta(months=2)
if type == 'electric':
domain.append(('archives_state', '!=', 'stop'))
model = 'meter.archives.line'
+ domain.extend([
+ ('archives_id.is_virtual_meter', '!=', True),
+ '|',
+ ('archives_id.end_time', '=', False),
+ ('archives_id.end_time', '<=', two_months_ago)
+ ])
else:
domain.append(('water_state', '!=', 'stop'))
model = 'meter.water.line'
From be3ea250fbf4a4c2de14fd5df7f85583b61a9a87 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: Thu, 25 Dec 2025 14:33:47 +0800
Subject: [PATCH 24/71] =?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
---
.../models/yuthon_hr_employee.py | 22 +++++++++++++++++++
.../wizard/property_reconciliation_wizard.py | 2 ++
2 files changed, 24 insertions(+)
diff --git a/yuthon_hr_employee/models/yuthon_hr_employee.py b/yuthon_hr_employee/models/yuthon_hr_employee.py
index c7d1b7bfe..051661af5 100644
--- a/yuthon_hr_employee/models/yuthon_hr_employee.py
+++ b/yuthon_hr_employee/models/yuthon_hr_employee.py
@@ -286,6 +286,28 @@ class YuthonHrEmployee(models.Model):
else:
record.date_end = None
+ def renew(self):
+ employee_ids = self.env["hr.employee"].browse(
+ self._context.get("active_ids", self._context.get("active_id"))
+ )
+ for record in employee_ids:
+ if len(record) > 1:
+ raise UserError("只能选择一个员工续签")
+ return {
+ "name": "续签",
+ "type": "ir.actions.act_window",
+ "res_model": "yuthon.renewal.approval",
+ "view_mode": "form",
+ "context": {
+ "default_employee_id": self.employee_id.id,
+ "default_current_status": self.employee_id.contract_id.date_end,
+ "default_department1_id": self.employee_id.department_id.id,
+ "default_contract_id": self.employee_id.contract_id.id,
+ },
+ }
+
+
+
def update_social_base(self):
current_year = fields.Date.today().year
group_company = self.env['res.company'].search([('name', '=', '集团本部')], limit=1)
diff --git a/yuthon_property_approval/wizard/property_reconciliation_wizard.py b/yuthon_property_approval/wizard/property_reconciliation_wizard.py
index a25031ea2..df19bfe17 100644
--- a/yuthon_property_approval/wizard/property_reconciliation_wizard.py
+++ b/yuthon_property_approval/wizard/property_reconciliation_wizard.py
@@ -538,6 +538,8 @@ class PropertyReconciliationWizard(models.Model):
]
# 检查是否已有相同记录
existing_record = self.env['property.accounts.receivable'].search(check_domain)
+ if len(existing_record)>1:
+ raise UserError(f'合同{line.contract_id.contract_code}应收日期为{line.due_date}的违约金存在多条相同记录,请检查数据')
is_reconciliation = round(line.amount,2) == round(line.rent, 2)
receivable_id = self.env['property.accounts.receivable']
if not existing_record and is_create:
From acdf344fb0d8327f59a78082e778f7f873103ce0 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: Thu, 25 Dec 2025 14:45:49 +0800
Subject: [PATCH 25/71] =?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
---
.../wizard/property_reconciliation_wizard.py | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/yuthon_property_approval/wizard/property_reconciliation_wizard.py b/yuthon_property_approval/wizard/property_reconciliation_wizard.py
index df19bfe17..1980fe84b 100644
--- a/yuthon_property_approval/wizard/property_reconciliation_wizard.py
+++ b/yuthon_property_approval/wizard/property_reconciliation_wizard.py
@@ -538,8 +538,6 @@ class PropertyReconciliationWizard(models.Model):
]
# 检查是否已有相同记录
existing_record = self.env['property.accounts.receivable'].search(check_domain)
- if len(existing_record)>1:
- raise UserError(f'合同{line.contract_id.contract_code}应收日期为{line.due_date}的违约金存在多条相同记录,请检查数据')
is_reconciliation = round(line.amount,2) == round(line.rent, 2)
receivable_id = self.env['property.accounts.receivable']
if not existing_record and is_create:
@@ -588,9 +586,13 @@ class PropertyReconciliationWizard(models.Model):
'is_write': True if line.amount != 0 else False,
'is_penalty': True,
'reconciliation_date': rec.actual_date if line.amount != 0 else None,
- 'receivable_id': receivable_id.id,
+ 'receivable_id': receivable_id[0].id,
'amount': line.amount,
})
+ # 删除多余的违约金数据
+ if len(receivable_id) > 1:
+ receivable_id = existing_record[1:]
+ receivable_id.unlink()
rec.amount_been_reconciled += line.amount
yes_amount += line.amount
@@ -609,7 +611,6 @@ class PropertyReconciliationWizard(models.Model):
if unreconciled_receivables:
remaining_contract_ids.append(contract.id)
-
class PropertyReconciliationLine(models.Model):
_name = 'property.reconciliation.line'
_description = '对账明细'
From 3f51aba487a3868bc7b72aa4ea5842e136f98671 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: Thu, 25 Dec 2025 15:47:33 +0800
Subject: [PATCH 26/71] =?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
---
yuthon_issue/models/issue_approval_decision.py | 1 +
yuthon_issue/views/issue_approval_decision_views.xml | 8 +++++---
yuthon_maintain/models/property_device_repair.py | 3 +--
3 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/yuthon_issue/models/issue_approval_decision.py b/yuthon_issue/models/issue_approval_decision.py
index 40e941104..fe423ce41 100644
--- a/yuthon_issue/models/issue_approval_decision.py
+++ b/yuthon_issue/models/issue_approval_decision.py
@@ -27,6 +27,7 @@ class IssueApprovalDecision(models.Model):
end_date = fields.Date(string="失效日期")
remarks = fields.Text(string='备注')
issue_approval_id = fields.Many2one('issue.approval', string="关联议题审批")
+ version = fields.Char(string="版本", default="V3.0")
def _get_default_company(self):
company = self.env['res.company'].search([('name', '=', '集团本部')], limit=1)
diff --git a/yuthon_issue/views/issue_approval_decision_views.xml b/yuthon_issue/views/issue_approval_decision_views.xml
index 11f01459e..8bc051342 100644
--- a/yuthon_issue/views/issue_approval_decision_views.xml
+++ b/yuthon_issue/views/issue_approval_decision_views.xml
@@ -20,6 +20,7 @@
+
@@ -47,14 +48,14 @@
-
-
-
+
+
+
@@ -62,6 +63,7 @@
+
diff --git a/yuthon_maintain/models/property_device_repair.py b/yuthon_maintain/models/property_device_repair.py
index 951e84e2e..9078e2f8a 100644
--- a/yuthon_maintain/models/property_device_repair.py
+++ b/yuthon_maintain/models/property_device_repair.py
@@ -18,7 +18,6 @@ class PropertyDeviceRelief(models.Model):
company_id = fields.Many2one(related='users_id.employee_id.company_id', string="公司")
software_processing_id = fields.Many2one('software.issues.processing', string="设备类型")
problem_description = fields.Text(string="问题描述")
- remake = fields.Text(string="问题描述")
report_state = fields.Selection([('to', '待处理'), ('done', '已处理')], string='状态', default='to')
create_time = fields.Date(string="填报日期", default=fields.Datetime.now)
urgency_level = fields.Selection([('normal', '普件'), ('urgent', '急件'), ('emergency', '特急件')], string='紧急度',
@@ -38,7 +37,7 @@ class PropertyDeviceRelief(models.Model):
def _compute_name(self):
for rec in self:
if rec.users_id and rec.software_processing_id:
- rec.name = f" {rec.software_processing_id.name}-{rec.users_id.name}-{rec.remake}"
+ rec.name = f"{rec.users_id.name}-{rec.software_processing_id.name}-{rec.problem_description}"
def get_no_read_count(self):
From f2410593706338592cf623d8d5151ccfca9bea8e 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: Thu, 25 Dec 2025 16:44:24 +0800
Subject: [PATCH 27/71] =?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
---
yuthon_maintain/models/property_device_repair.py | 14 +++++++++++++-
.../views/property_device_repair_views.xml | 10 +++++++---
yuthon_will_task/views/yuthon_will_task_views.xml | 4 ++--
3 files changed, 22 insertions(+), 6 deletions(-)
diff --git a/yuthon_maintain/models/property_device_repair.py b/yuthon_maintain/models/property_device_repair.py
index 9078e2f8a..dbe632474 100644
--- a/yuthon_maintain/models/property_device_repair.py
+++ b/yuthon_maintain/models/property_device_repair.py
@@ -18,7 +18,7 @@ class PropertyDeviceRelief(models.Model):
company_id = fields.Many2one(related='users_id.employee_id.company_id', string="公司")
software_processing_id = fields.Many2one('software.issues.processing', string="设备类型")
problem_description = fields.Text(string="问题描述")
- report_state = fields.Selection([('to', '待处理'), ('done', '已处理')], string='状态', default='to')
+ report_state = fields.Selection([('to_submitted', '待提交'), ('to', '待处理'), ('done', '已处理')], string='状态', default='to_submitted')
create_time = fields.Date(string="填报日期", default=fields.Datetime.now)
urgency_level = fields.Selection([('normal', '普件'), ('urgent', '急件'), ('emergency', '特急件')], string='紧急度',
default='normal')
@@ -39,12 +39,24 @@ class PropertyDeviceRelief(models.Model):
if rec.users_id and rec.software_processing_id:
rec.name = f"{rec.users_id.name}-{rec.software_processing_id.name}-{rec.problem_description}"
+ def device_delete(self):
+ self.unlink()
+
+ def open_record(self):
+ return {
+ "type": "ir.actions.act_window",
+ "res_model": 'processing.order.approval',
+ "res_id": self.processing_order_id.id,
+ "name": '详情',
+ "view_mode": "form",
+ }
def get_no_read_count(self):
return self.search_count([('report_state', '=', 'to')])
def pull_order(self):
soong_workflow_line_list = []
+ self.report_state = 'to'
if self.env['processing.order.approval'].search([('device_id', '=', self.id)]):
raise UserError('该设备已生成处理单')
order_id = self.env['processing.order.approval'].create({
diff --git a/yuthon_maintain/views/property_device_repair_views.xml b/yuthon_maintain/views/property_device_repair_views.xml
index 63af193ca..0f73b7abf 100644
--- a/yuthon_maintain/views/property_device_repair_views.xml
+++ b/yuthon_maintain/views/property_device_repair_views.xml
@@ -4,13 +4,15 @@
property.device.repair.tree
property.device.repair
-
+
-
+
+
+
@@ -18,7 +20,7 @@
property.device.repair.form
property.device.repair
-
diff --git a/yuthon_maintain/models/processing_order_approval.py b/yuthon_maintain/models/processing_order_approval.py
index 33de5f59c..07ecc4ae5 100644
--- a/yuthon_maintain/models/processing_order_approval.py
+++ b/yuthon_maintain/models/processing_order_approval.py
@@ -100,6 +100,26 @@ class ProcessingOrderApproval(models.Model):
else:
record.contract_id = False
+ def open_record(self):
+ if self.device_id:
+ return {
+ 'type': 'ir.actions.act_window',
+ 'name': self.device_id.display_name,
+ 'res_model': 'property.device.repair',
+ 'res_id': self.device_id.id,
+ 'view_mode': 'form',
+ 'view_type': 'form',
+ }
+ elif self.repair_id:
+ return {
+ 'type': 'ir.actions.act_window',
+ 'name': self.repair_id.display_name,
+ 'res_model': 'property.report.repair',
+ 'res_id': self.repair_id.id,
+ 'view_mode': 'form',
+ 'view_type': 'form',
+ }
+
@api.onchange('repair_id')
def onchange_repair_id(self):
if self.repair_id:
diff --git a/yuthon_maintain/views/processing_order_approval_views.xml b/yuthon_maintain/views/processing_order_approval_views.xml
index 286816ce0..d7bf900b3 100644
--- a/yuthon_maintain/views/processing_order_approval_views.xml
+++ b/yuthon_maintain/views/processing_order_approval_views.xml
@@ -43,8 +43,9 @@
-
+
+
@@ -53,7 +54,6 @@
-
@@ -70,12 +70,11 @@
-
-
+
diff --git a/yuthon_purchase/models/purchase_workflow.py b/yuthon_purchase/models/purchase_workflow.py
index 5ea9e7a37..f8c9b9f86 100644
--- a/yuthon_purchase/models/purchase_workflow.py
+++ b/yuthon_purchase/models/purchase_workflow.py
@@ -30,7 +30,7 @@ class PurchaseWorkflow(models.Model):
work_end = fields.Boolean(string="审批结束", default=False, tracking=True)
purchase_order_id = fields.Many2one('purchase.order', string="采购订单", readonly=True)
- purchase_type = fields.Selection([('fixed', '固定资产'), ('low', '低值易耗'), ('service', '服务')],
+ purchase_type = fields.Selection([('fixed', '固定资产'), ('low', '低值易耗'), ('service', '服务'), ('day', '日常消耗品明细')],
string="采购类型", required=True, default='fixed')
service_content = fields.Text(string="服务内容")
diff --git a/yuthon_purchase/views/purchase_workflow_views.xml b/yuthon_purchase/views/purchase_workflow_views.xml
index f7b3b9aec..1b060285c 100644
--- a/yuthon_purchase/views/purchase_workflow_views.xml
+++ b/yuthon_purchase/views/purchase_workflow_views.xml
@@ -92,6 +92,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
From 1e5867c286584c84232d4de644a63d13f5069116 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: Thu, 25 Dec 2025 18:06:33 +0800
Subject: [PATCH 31/71] =?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
---
yuthon_purchase/models/purchase_workflow.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/yuthon_purchase/models/purchase_workflow.py b/yuthon_purchase/models/purchase_workflow.py
index f8c9b9f86..b6613f89d 100644
--- a/yuthon_purchase/models/purchase_workflow.py
+++ b/yuthon_purchase/models/purchase_workflow.py
@@ -30,7 +30,7 @@ class PurchaseWorkflow(models.Model):
work_end = fields.Boolean(string="审批结束", default=False, tracking=True)
purchase_order_id = fields.Many2one('purchase.order', string="采购订单", readonly=True)
- purchase_type = fields.Selection([('fixed', '固定资产'), ('low', '低值易耗'), ('service', '服务'), ('day', '日常消耗品明细')],
+ purchase_type = fields.Selection([('fixed', '固定资产'), ('low', '低值易耗'), ('service', '服务'), ('day', '日常消耗品')],
string="采购类型", required=True, default='fixed')
service_content = fields.Text(string="服务内容")
From 5a852d22298cb24d4def70116646f9a8ced94d30 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: Thu, 25 Dec 2025 18:11:39 +0800
Subject: [PATCH 32/71] =?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
---
yuthon_maintain/models/processing_order_approval.py | 2 ++
yuthon_maintain/views/processing_order_approval_views.xml | 4 +++-
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/yuthon_maintain/models/processing_order_approval.py b/yuthon_maintain/models/processing_order_approval.py
index 07ecc4ae5..982e7b7ab 100644
--- a/yuthon_maintain/models/processing_order_approval.py
+++ b/yuthon_maintain/models/processing_order_approval.py
@@ -109,6 +109,7 @@ class ProcessingOrderApproval(models.Model):
'res_id': self.device_id.id,
'view_mode': 'form',
'view_type': 'form',
+ 'target': 'current'
}
elif self.repair_id:
return {
@@ -118,6 +119,7 @@ class ProcessingOrderApproval(models.Model):
'res_id': self.repair_id.id,
'view_mode': 'form',
'view_type': 'form',
+ 'target': 'current'
}
@api.onchange('repair_id')
diff --git a/yuthon_maintain/views/processing_order_approval_views.xml b/yuthon_maintain/views/processing_order_approval_views.xml
index d7bf900b3..fd2429116 100644
--- a/yuthon_maintain/views/processing_order_approval_views.xml
+++ b/yuthon_maintain/views/processing_order_approval_views.xml
@@ -45,7 +45,6 @@
-
@@ -55,6 +54,9 @@
+
+
+
From 2e4513a958505580e305143ed4874cac7c77f2ac 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: Thu, 25 Dec 2025 18:13:31 +0800
Subject: [PATCH 33/71] =?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
---
yuthon_maintain/models/processing_order_approval.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/yuthon_maintain/models/processing_order_approval.py b/yuthon_maintain/models/processing_order_approval.py
index 982e7b7ab..67042f1a8 100644
--- a/yuthon_maintain/models/processing_order_approval.py
+++ b/yuthon_maintain/models/processing_order_approval.py
@@ -109,7 +109,7 @@ class ProcessingOrderApproval(models.Model):
'res_id': self.device_id.id,
'view_mode': 'form',
'view_type': 'form',
- 'target': 'current'
+ 'target': 'new'
}
elif self.repair_id:
return {
@@ -119,7 +119,7 @@ class ProcessingOrderApproval(models.Model):
'res_id': self.repair_id.id,
'view_mode': 'form',
'view_type': 'form',
- 'target': 'current'
+ 'target': 'new'
}
@api.onchange('repair_id')
From 1a1cf7b489e2930957040f3976b9a0f403bab505 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: Thu, 25 Dec 2025 18:17:34 +0800
Subject: [PATCH 34/71] =?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
---
yuthon_hr_employee/models/yuthon_hr_employee.py | 2 +-
yuthon_maintain/views/property_device_repair_views.xml | 3 +++
yuthon_maintain/views/property_report_repair.xml | 3 +++
3 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/yuthon_hr_employee/models/yuthon_hr_employee.py b/yuthon_hr_employee/models/yuthon_hr_employee.py
index 051661af5..0c6e29c9d 100644
--- a/yuthon_hr_employee/models/yuthon_hr_employee.py
+++ b/yuthon_hr_employee/models/yuthon_hr_employee.py
@@ -299,7 +299,7 @@ class YuthonHrEmployee(models.Model):
"res_model": "yuthon.renewal.approval",
"view_mode": "form",
"context": {
- "default_employee_id": self.employee_id.id,
+ "default_employee_id": self.id,
"default_current_status": self.employee_id.contract_id.date_end,
"default_department1_id": self.employee_id.department_id.id,
"default_contract_id": self.employee_id.contract_id.id,
diff --git a/yuthon_maintain/views/property_device_repair_views.xml b/yuthon_maintain/views/property_device_repair_views.xml
index 43d3dc357..ef7abfd3c 100644
--- a/yuthon_maintain/views/property_device_repair_views.xml
+++ b/yuthon_maintain/views/property_device_repair_views.xml
@@ -45,6 +45,9 @@