Permalink
Browse files

FEATURE View and select groups for a specific member via the member p…

…opup in admin/security (requires EDIT_PERMISSIONS)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@98880 467b73ca-7a2a-4603-9d3b-597d59a354a9
  • Loading branch information...
1 parent e26158c commit aea2f94a5e840cba22134a822b5a91eec84310a7 @chillu chillu committed Feb 12, 2010
Showing with 7 additions and 0 deletions.
  1. +7 −0 security/Member.php
View
@@ -973,9 +973,16 @@ public function getCMSFields() {
$mainFields->removeByName('LastVisited');
$fields->removeByName('Subscriptions');
+
// Groups relation will get us into logical conflicts because
// Members are displayed within group edit form in SecurityAdmin
$fields->removeByName('Groups');
+
+ if(Permission::check('EDIT_PERMISSIONS')) {
+ $groupsField = new TreeMultiselectField('Groups', false, 'Group');
+ $fields->findOrMakeTab('Root.Groups', singleton('Group')->i18n_plural_name());
+ $fields->addFieldToTab('Root.Groups', $groupsField);
+ }
$this->extend('updateCMSFields', $fields);

0 comments on commit aea2f94

Please sign in to comment.