Hello

Great module, I was looking this kind of module a lot of time!

Maybe this module could integrate with user_permissions.module. I want roles to administer only a collection of permissions for each user.

Another thing: What about using user.module theme for lock_permissions administration page? It does not seems difficult.

Please excuse my prehistoric english, it's not my native language.
Regards

CommentFileSizeAuthor
#6 user_permissions_lock.patch745 bytesingacosta

Comments

ingacosta’s picture

Status: Active » Needs review

Hi,
I can do it changing line 73 in permissions_lock.module:

if ($form_id == 'user_admin_perm')

with this:

if ($form_id == 'user_admin_perm' || $form_id == 'user_permissions_profile_permissions_form')

svendecabooter’s picture

Status: Needs review » Needs work

Could you attach a real patch?
I'll try to test it and commit if that works :)

ingacosta’s picture

Status: Needs work » Needs review

Of course. Here you go.

ingacosta’s picture

I try again. It seems I can't upload the patchfile.

ingacosta’s picture

Maybe it's a drupal site error. I can attach the file but when I save the comment, the file disappear

Here is a copy of the patch file:

--- permissions_lock.module	2009-01-17 16:10:24.000000000 -0200
+++ permissions_lock_new.module	2009-02-19 10:36:20.671875000 -0200
@@ -70,7 +70,7 @@ function permissions_lock_perm() {
  * Implementation of hook_form_alter().
  */
 function permissions_lock_form_alter(&$form, &$form_state, $form_id) {
-  if ($form_id == 'user_admin_perm') {
+  if ($form_id == 'user_admin_perm' || $form_id == 'user_permissions_profile_permissions_form') {
     // Get all available permissions in the form
     $available_permissions = _permissions_lock_get_form_available_permissions($form);
 
@@ -113,7 +113,7 @@ function permissions_lock_form_alter(&$f
         _permissions_lock_cleanup_orphan_headers($form);
       }
     }
-  }
+  }	
 }
 
 /**
ingacosta’s picture

StatusFileSize
new745 bytes
svendecabooter’s picture

Thanks for the patch ingacosta.
This has been committed.

svendecabooter’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

akalata’s picture

Adding a note, since I was having some difficulty getting a truncated list in user/#/permissions (it was listing all available permissions, but no checkboxes at all).

I was able to get it to work by unlocking all roles.