Company asked me to create an agent, that can only manage other agents. I've created new group "user_manager", set permissions for this group in admin module registration (access to managing users and adding roles to users), created new agent "x" and added him to group. So now agent "x" can create new users, assign roles to users, but can't add himself to "admin" group and gain access to whole system. Roles and groups are set by main system admins. So far it works as I expected, BUT after creating new agent, agent "x" receives error "permission denied", because AdminUserGroup module is automatically loaded and agent "x" has no access to this module. New user is properly created anyway.
Is it possible to change module loaded after creating user from AdminUserGroup to AdminRoleUser? Is there any option in system config or should I change the code in AdminUser module?
Or maybe there is simpler way to creating such user manager.
change module loaded after creating new agent
Moderator: crythias
-
- Znuny expert
- Posts: 213
- Joined: 04 Nov 2012, 23:58
- Znuny Version: OTRS 4.x
- Real Name: Esteban
- Company: NORTON DE COLOMBIA
Re: change module loaded after creating new agent
Well, According to https://github.com/OTRS/otrs/blob/rel-4 ... er.pm#L410 if you disable the AdminUserGroup module, it would redirect you to AdminRoleUser module.. but i guess that disabling AdminUserGroup is not an option for you since you may use it in a future.. so yeah, most likely you will have to edit the code
Edit:
By the looks of the AdminUserGroup, it seems that it will display only the permissions/group which the user has access to. So a better solution, would be going to SysConfig -> "Framework" ->" Frontend::Admin::ModuleRegistration" look for " Frontend::Module###AdminUserGroup" and add a new row with the name of the group the user creating users belongs to
Edit:
By the looks of the AdminUserGroup, it seems that it will display only the permissions/group which the user has access to. So a better solution, would be going to SysConfig -> "Framework" ->" Frontend::Admin::ModuleRegistration" look for " Frontend::Module###AdminUserGroup" and add a new row with the name of the group the user creating users belongs to