[drupal-devel] [feature] Allow descriptions for permissions

stefan nagtegaal drupal-devel at drupal.org
Mon Sep 19 09:32:15 UTC 2005


Issue status update for 
http://drupal.org/node/30984
Post a follow up: 
http://drupal.org/project/comments/add/30984

 Project:      Drupal
 Version:      cvs
 Component:    user.module
 Category:     feature requests
 Priority:     normal
 Assigned to:  Anonymous
 Reported by:  timcn
 Updated by:   stefan nagtegaal
-Status:       patch (code needs work)
+Status:       patch (code needs review)
 Attachment:   http://drupal.org/files/issues/user-permission-help.patch (1.65 KB)

Rerolled patch... I like this idea!




stefan nagtegaal



Previous comments:
------------------------------------------------------------------------

Mon, 12 Sep 2005 11:18:12 +0000 : timcn

Attachment: http://drupal.org/files/issues/user_32.patch (1.59 KB)

I extended the user.module in order to allow descriptions for
permissions because it is sometimes difficult to figure out what a
certain permission really does. In hook_perm() you can now return an
array like that (example taken from node.module):

<?php
function node_perm() {
  return array(
    'administer nodes' => 'Allows editing and deleting of all nodes',
    'access content' => 'Allows to view content'
  );
}
?>




You can also freely mix "described" permissions with old/regular ones;
i.e. it does not break the current permission system.




------------------------------------------------------------------------

Mon, 19 Sep 2005 00:57:49 +0000 : Uwe Hermann

Patch doesn't apply anymore.







More information about the drupal-devel mailing list