diff --git a/yuthon_salary/models/inherit_hr_payroll_structure.py b/yuthon_salary/models/inherit_hr_payroll_structure.py
index 09d59092c..60ecb797e 100644
--- a/yuthon_salary/models/inherit_hr_payroll_structure.py
+++ b/yuthon_salary/models/inherit_hr_payroll_structure.py
@@ -6,6 +6,7 @@ class HrPayrollStructure(models.Model):
_order = 'sequence asc'
lv_id = fields.Many2one('hr.payroll.structure.type', string="级别")
+ lv_name = fields.Char(related='lv_id.name', string='级别名称', store=True)
name = fields.Char(string="职级名称")
sequence = fields.Char(related='lv_id.sequence', string='级别序号', store=True)
yuthon_company = fields.Selection([('thtz', '天河投资集团'), ('thwg', '天河物管'), ('thlc', '天河粮储')], string='所属公司')
diff --git a/yuthon_salary/models/inherit_hr_salary_rule.py b/yuthon_salary/models/inherit_hr_salary_rule.py
index 0682ce493..c2d4c7a17 100644
--- a/yuthon_salary/models/inherit_hr_salary_rule.py
+++ b/yuthon_salary/models/inherit_hr_salary_rule.py
@@ -8,7 +8,8 @@ class InheritHrSalaryRule(models.Model):
category_id = fields.Many2one('hr.salary.rule.category', required=False, string='类别')
yuthon_company = fields.Selection([('thtz', '天河投资集团'), ('thwg', '天河物管'), ('thlc', '天河粮储')],
string='所属公司')
-
+ amount_fix = fields.Float(string='固定金额', group_operator=None)
+
def action_yuthon_salary_wizard(self):
return {
"type": "ir.actions.act_window",
diff --git a/yuthon_salary/views/inherit_hr_payroll_structure_views.xml b/yuthon_salary/views/inherit_hr_payroll_structure_views.xml
index bb97720e7..80891c9d5 100644
--- a/yuthon_salary/views/inherit_hr_payroll_structure_views.xml
+++ b/yuthon_salary/views/inherit_hr_payroll_structure_views.xml
@@ -17,6 +17,7 @@
+
@@ -52,7 +53,7 @@
-
+
@@ -61,27 +62,27 @@
全部
hr.payroll.structure
tree,form,search
- {'search_default_group_lv_id': 1}
+ {'search_default_group_lv_name': 1}
天河投资
hr.payroll.structure
tree,form,search
- {'search_default_group_lv_id': 1}
+ {'search_default_group_lv_name': 1}
[('yuthon_company', '=' , 'thtz')]
天河粮储
hr.payroll.structure
tree,form,search
- {'search_default_group_lv_id': 1}
+ {'search_default_group_lv_name': 1}
[('yuthon_company', '=', 'thlc')]
天河物管
hr.payroll.structure
tree,form,search
- {'search_default_group_lv_id': 1}
+ {'search_default_group_lv_name': 1}
[('yuthon_company', '=', 'thwg')]
\ No newline at end of file
diff --git a/yuthon_salary/wizard/yuthon_salary_wizard.py b/yuthon_salary/wizard/yuthon_salary_wizard.py
index 31403fea0..eb66973d4 100644
--- a/yuthon_salary/wizard/yuthon_salary_wizard.py
+++ b/yuthon_salary/wizard/yuthon_salary_wizard.py
@@ -149,6 +149,8 @@ class YuthonSalaryWizard(models.Model):
for salary, r in zip(salary_dates, row[3:15]):
name_pinyin = pinyin(salary.value, style=Style.FIRST_LETTER)
abbreviation = "".join([p[0][0] for p in name_pinyin]).upper()
+ if type(r.value) == str:
+ r.value = 0
salary_date = {
'sequence': row[0].value,
'code': yuthon_company2 + abbreviation,