From 7459f89e4f0db551519168112f8f67eb4b50dcd6 Mon Sep 17 00:00:00 2001
From: zhou <123@>
Date: Tue, 20 May 2025 09:42:22 +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
---
yuthon_salary/__manifest__.py | 1 +
yuthon_salary/models/__init__.py | 3 ++-
.../models/yuthon_welfare_expenses.py | 10 ++++++++++
yuthon_salary/security/ir.model.access.csv | 1 +
.../views/yuthon_welfare_expenses_views.xml | 18 ++++++++++++++++++
yuthon_work_brand/views/hr_menus.xml | 5 +++++
6 files changed, 37 insertions(+), 1 deletion(-)
create mode 100644 yuthon_salary/models/yuthon_welfare_expenses.py
create mode 100644 yuthon_salary/views/yuthon_welfare_expenses_views.xml
diff --git a/yuthon_salary/__manifest__.py b/yuthon_salary/__manifest__.py
index fadf8d798..f3e374e22 100644
--- a/yuthon_salary/__manifest__.py
+++ b/yuthon_salary/__manifest__.py
@@ -25,6 +25,7 @@
'views/yuthon_salary_project_views.xml',
'views/yuthon_payroll_labor_views.xml',
'views/yuthon_salary_documents_views.xml',
+ 'views/yuthon_welfare_expenses_views.xml',
'views/yuthon_payroll_retired_views.xml',
'views/yuthon_salary_year_views.xml',
'wizard/yuthon_salary_wizard_views.xml',
diff --git a/yuthon_salary/models/__init__.py b/yuthon_salary/models/__init__.py
index 776b35227..e4b15a246 100644
--- a/yuthon_salary/models/__init__.py
+++ b/yuthon_salary/models/__init__.py
@@ -10,4 +10,5 @@ from . import yuthon_salary_documents
from . import yuthon_salary_year
from . import yuthon_salary_project
from . import yuthon_salary_asset
-from . import salary_payroll_distribution
\ No newline at end of file
+from . import salary_payroll_distribution
+from . import yuthon_welfare_expenses
\ No newline at end of file
diff --git a/yuthon_salary/models/yuthon_welfare_expenses.py b/yuthon_salary/models/yuthon_welfare_expenses.py
new file mode 100644
index 000000000..1b94fba87
--- /dev/null
+++ b/yuthon_salary/models/yuthon_welfare_expenses.py
@@ -0,0 +1,10 @@
+from odoo import api, fields, models
+from decimal import ROUND_HALF_UP, Decimal
+
+
+class YuthonWelfareExpenses(models.Model):
+ _name = 'yuthon.welfare.expenses'
+ _description = '福利费'
+
+ employee_id = fields.Many2one('hr.employee', string="姓名")
+ fees = fields.Float(string="费用")
\ No newline at end of file
diff --git a/yuthon_salary/security/ir.model.access.csv b/yuthon_salary/security/ir.model.access.csv
index 87f08cda7..45fdd68a4 100644
--- a/yuthon_salary/security/ir.model.access.csv
+++ b/yuthon_salary/security/ir.model.access.csv
@@ -29,3 +29,4 @@ access_salary_year_wizard,access_salary_year_wizard,model_salary_year_wizard,bas
access_yuthon_salary_project, access_yuthon_salary_project,model_yuthon_salary_project,base.group_user,1,1,1,1
access_yuthon_salary_asset, access_yuthon_salary_asset,model_yuthon_salary_asset,base.group_user,1,1,1,1
access_salary_payroll_distribution,access_salary_payroll_distribution,model_salary_payroll_distribution,base.group_user,1,1,1,1
+access_yuthon_welfare_expenses,access_yuthon_welfare_expenses,model_yuthon_welfare_expenses,base.group_user,1,1,1,1
diff --git a/yuthon_salary/views/yuthon_welfare_expenses_views.xml b/yuthon_salary/views/yuthon_welfare_expenses_views.xml
new file mode 100644
index 000000000..91e0cb3b2
--- /dev/null
+++ b/yuthon_salary/views/yuthon_welfare_expenses_views.xml
@@ -0,0 +1,18 @@
+
+
+
+ yuthon.welfare.expenses.tree
+ yuthon.welfare.expenses
+
+
+
+
+
+
+
+
+ 福利费
+ yuthon.welfare.expenses
+ tree
+
+
\ No newline at end of file
diff --git a/yuthon_work_brand/views/hr_menus.xml b/yuthon_work_brand/views/hr_menus.xml
index 64a62025c..fa7cafd21 100644
--- a/yuthon_work_brand/views/hr_menus.xml
+++ b/yuthon_work_brand/views/hr_menus.xml
@@ -209,6 +209,11 @@
parent="human_resources_salary_root_board"
action="yuthon_salary.action_view_hr_payslip_month_form2"
sequence="3"/>
+