diff --git a/yuthon_issue/views/issue_library_views.xml b/yuthon_issue/views/issue_library_views.xml
index 41db3d7aa..fc162139a 100644
--- a/yuthon_issue/views/issue_library_views.xml
+++ b/yuthon_issue/views/issue_library_views.xml
@@ -111,6 +111,9 @@
decoration-info="issue_state == 'will'"
decoration-success="issue_state == 'done'"
decoration-muted="issue_state == 'cancel'">
+
diff --git a/yuthon_property_approval/__manifest__.py b/yuthon_property_approval/__manifest__.py
index d2e448b48..d1b631c8d 100644
--- a/yuthon_property_approval/__manifest__.py
+++ b/yuthon_property_approval/__manifest__.py
@@ -119,7 +119,9 @@
'report/property_supervising_approval_print_report.xml',
'report/property_supervising_approval_print_templates.xml',
'report/property_open_rent_print_report.xml',
- 'report/property_open_rent_print_templates.xml'
+ 'report/property_open_rent_print_templates.xml',
+ 'report/property_project_works_print_report.xml',
+ 'report/property_project_works_print_templates.xml'
],
diff --git a/yuthon_property_approval/models/property_project_works.py b/yuthon_property_approval/models/property_project_works.py
index e05713ac6..c38ce1ccd 100644
--- a/yuthon_property_approval/models/property_project_works.py
+++ b/yuthon_property_approval/models/property_project_works.py
@@ -28,4 +28,12 @@ class PropertyProjectWorks(models.Model):
return self._description if self._description else self._name
name_title = fields.Char(default=_get_default_name_title)
- self_users_ids = fields.Many2many('res.users', string="当前经办人", default=lambda self: [(6, 0, [self.env.user.id])])
\ No newline at end of file
+ self_users_ids = fields.Many2many('res.users', string="当前经办人", default=lambda self: [(6, 0, [self.env.user.id])])
+
+ def action_print_property_project_works(self):
+ """打印项目工程审批表"""
+ # 确保只针对单条记录生成打印
+ self.ensure_one()
+ # 通过 XML 中定义的报表动作记录触发 PDF 打印
+ report_ref = self.env.ref('yuthon_property_approval.action_property_project_works_print_report')
+ return report_ref.report_action(self)
\ No newline at end of file
diff --git a/yuthon_property_approval/report/property_project_works_print_report.xml b/yuthon_property_approval/report/property_project_works_print_report.xml
new file mode 100644
index 000000000..ad3e0ed64
--- /dev/null
+++ b/yuthon_property_approval/report/property_project_works_print_report.xml
@@ -0,0 +1,22 @@
+
+
+
+
+ Property Project Works A4
+ A4
+ 5
+ Portrait
+
+
+
+ 项目工程
+
+ property.project.works
+ qweb-pdf
+ yuthon_property_approval.property_project_works_print_template
+ yuthon_property_approval.property_project_works_print_template
+ '项目工程%s_%s' % (object.name or '', object.code or '')
+
+ report
+
+
diff --git a/yuthon_property_approval/report/property_project_works_print_templates.xml b/yuthon_property_approval/report/property_project_works_print_templates.xml
new file mode 100644
index 000000000..af5daa3c1
--- /dev/null
+++ b/yuthon_property_approval/report/property_project_works_print_templates.xml
@@ -0,0 +1,80 @@
+
+
+
+
+
+
+
+
+
+
+
项目工程
+
+
+
+
+ 流水号:
+
+
+
+
+
+ | 工程名称 |
+ |
+ 标题 |
+ |
+
+
+ | 流程环节 |
+ |
+ 紧急度 |
+ |
+
+
+ | 签订日期 |
+ |
+ 验收日期 |
+ |
+
+
+ | 总金额 |
+ |
+ 应付 |
+ |
+
+
+ | 已付 |
+ |
+ 未付 |
+ |
+
+
+
+
+
审批详情
+
+
+
+
+
+
+
+
diff --git a/yuthon_property_approval/views/property_project_works_viwes.xml b/yuthon_property_approval/views/property_project_works_viwes.xml
index 828eb8773..4d6349c4a 100644
--- a/yuthon_property_approval/views/property_project_works_viwes.xml
+++ b/yuthon_property_approval/views/property_project_works_viwes.xml
@@ -17,6 +17,11 @@
property.project.works