summaryrefslogtreecommitdiffstats
path: root/application/modules/user
diff options
context:
space:
mode:
Diffstat (limited to 'application/modules/user')
-rw-r--r--application/modules/user/controllers/GroupController.php20
-rw-r--r--application/modules/user/views/scripts/group/show.phtml1
2 files changed, 12 insertions, 9 deletions
diff --git a/application/modules/user/controllers/GroupController.php b/application/modules/user/controllers/GroupController.php
index 7a136c8..9eca3e3 100644
--- a/application/modules/user/controllers/GroupController.php
+++ b/application/modules/user/controllers/GroupController.php
@@ -236,15 +236,19 @@ class User_GroupController extends Zend_Controller_Action
$groupGroupsMapper = new Application_Model_GroupGroupsMapper();
$parents = $groupGroupsMapper->getParentGroups($groupID);
$groupMapper = new Application_Model_GroupMapper();
- foreach($parents as $p){
+ $crawled = array();
+ foreach($parents as $p){
foreach($p as $a){
- $group = $groupMapper->find($a);
- if($groupID != $a)
- $r = $this->rolemapper->findBy(array('groupID' => $a,'inheritance'=>"1"));
- else
- $r = $this->rolemapper->findBy(array('groupID' => $a));
- foreach($r as $d){
- $roles[$group->getTitle()][] = $d;
+ if(!in_array($a,$crawled)){
+ $crawled[] = $a;
+ $group = $groupMapper->find($a);
+ if($groupID != $a)
+ $r = $this->rolemapper->findBy(array('groupID' => $a,'inheritance'=>"1"));
+ else
+ $r = $this->rolemapper->findBy(array('groupID' => $a));
+ foreach($r as $d){
+ $roles[$group->getTitle()][] = $d;
+ }
}
}
}
diff --git a/application/modules/user/views/scripts/group/show.phtml b/application/modules/user/views/scripts/group/show.phtml
index 386c782..fae7b44 100644
--- a/application/modules/user/views/scripts/group/show.phtml
+++ b/application/modules/user/views/scripts/group/show.phtml
@@ -194,7 +194,6 @@ if((Pbs_Acl::checkRight('gdmo') && $this->usergroup == $this->requestgroup) || (
function printRoleSelect($roleList) {
$s = '';
- #print_a($roleList);
echo "<select name=\"roleID\">";
foreach($roleList as $grouptitle=>$head) {
#print_a($grouptitle,$head);