资金管理权限

This commit is contained in:
李鹏宇
2026-05-07 17:49:50 +08:00
parent 0eb76d17d0
commit 32508f72b9
2 changed files with 10 additions and 1 deletions
+5
View File
@@ -61,9 +61,14 @@ class ResUsers(models.Model):
"""
# 定义受保护的群组,这些群组不会被角色自动添加或移除
protected_group_refs = [
# 财务相关群组
'account.group_account_manager',
'account.group_account_invoice',
'account.group_account_user',
'account.group_readonly',
# 薪资相关群组
'hr_payroll.group_hr_payroll_manager',
'hr_payroll.group_hr_payroll_user',
'yuthon_salary.group_jtbb_user',
'yuthon_salary.group_wg_user',
'yuthon_salary.group_lc_user',
+5 -1
View File
@@ -15,10 +15,14 @@ class ResUsers(models.Model):
# 新建用户后确保移除财务和薪资管理员权限组
groups_to_remove = []
group_refs = [
# 财务相关群组
'account.group_account_manager',
'account.group_account_invoice',
'account.group_account_user',
'account.group_readonly',
# 薪资相关群组
'hr_payroll.group_hr_payroll_manager',
# 薪资模块相关权限组
'hr_payroll.group_hr_payroll_user',
'yuthon_salary.group_jtbb_user', # 集团本部用户
'yuthon_salary.group_wg_user', # 物管公司用户
'yuthon_salary.group_lc_user', # 粮储公司用户