Closed (fixed)
Project:
Role Delegation
Version:
5.x-1.0
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Mar 2008 at 15:24 UTC
Updated:
14 May 2008 at 07:23 UTC
Hello,
I use role_delegation to permit some "super-users" to add users into some roles. When the role tab (ie role_delegation) is used to enter a user into a role, it seem that something is not did correctly.
I see this problem with two others modules. The first, content_access allow me to select which role can see which content type. The second is userlist, allow user hat have role X to see members list.
So, if I add a role with role_delegation, I get no access to theses modules, but if I go to the drupal's users editor, I see that the role has been added to the user. If I add a role with the build-in user editor, it's working with no problems.
Comments
Comment #1
david lesieur commentedRole Delegation works on the users_roles table. I'm not aware of anywhere else where per-user role data is stored. Perhaps content_access and userlist are doing specific things when a user is saved?
Comment #2
francisd commentedAlso, if I add the user with role_delegation and then I go to the "Access control" and save again (even without any modifications), it's working ! Hope that can help ;)
Comment #3
rssaddict commentedI think I've got this figured out: the user's menus are cached, so even though the permissions get updated, the relevant options aren't available to the user. In order to fix this, I added the line:
cache_clear_all($form_values['account']->uid .':', 'cache_menu', TRUE);to the end of the role_delegation_roles_form_submit function, which seems to solve the problem. Could you guys check and see if this fixes your issue, and if it does we can merge it into the module?
Comment #4
david lesieur commented@rssaddict: Good catch!
I've just committed the fix.
Comment #5
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.