summaryrefslogtreecommitdiffstats
path: root/application/modules/user/controllers
diff options
context:
space:
mode:
authormichael pereira2011-04-26 17:54:31 +0200
committermichael pereira2011-04-26 17:54:31 +0200
commitba6f441fe01b49f2836ee182a89632d4552d34e7 (patch)
treed18bf4ae2dd0296757e75a36005d026161f2cf92 /application/modules/user/controllers
parentMerge branch 'master' of openslx.org:lsfks/master-teamprojekt/pbs2 (diff)
downloadpbs2-ba6f441fe01b49f2836ee182a89632d4552d34e7.tar.gz
pbs2-ba6f441fe01b49f2836ee182a89632d4552d34e7.tar.xz
pbs2-ba6f441fe01b49f2836ee182a89632d4552d34e7.zip
config fix
Diffstat (limited to 'application/modules/user/controllers')
-rw-r--r--application/modules/user/controllers/ConfigController.php22
1 files changed, 14 insertions, 8 deletions
diff --git a/application/modules/user/controllers/ConfigController.php b/application/modules/user/controllers/ConfigController.php
index 6c6466c..e41c23e 100644
--- a/application/modules/user/controllers/ConfigController.php
+++ b/application/modules/user/controllers/ConfigController.php
@@ -107,20 +107,26 @@ class user_ConfigController extends Zend_Controller_Action
foreach ($bootos as $b)
if($b->getPublic() - $k >= 0 ){
$this->view->bootoslist[] = $b;
- if(Pbs_Acl::checkRight('cc'))
- $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('membershipID' => null, 'bootosID' => $b->getID()));
- else
- $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('membershipID' => null, 'bootosID' => $b->getID(), 'visible' => '1'));
+ if(Pbs_Acl::checkRight('cc')){
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $b->getGroupID(), 'membershipID' => null, 'bootosID' => $b->getID()));
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $groupID, 'membershipID' => null, 'bootosID' => $b->getID()));
+ }else{
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $b->getGroupID(), 'membershipID' => null, 'bootosID' => $b->getID(), 'visible' => '1'));
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $groupID, 'membershipID' => null, 'bootosID' => $b->getID(), 'visible' => '1'));
+ }
foreach ($this->view->configlist[$b->getID()] as $config){
$config->setCreated(date(Zend_Registry::get('dateformat'),$config->getCreated()));
}
}
elseif($k == 0 && $b->getPublic() == -1 && Pbs_Acl::checkRight('boc')){
$this->view->bootoslist[] = $b;
- if(Pbs_Acl::checkRight('cc'))
- $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('membershipID' => null, 'bootosID' => $b->getID()));
- else
- $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('membershipID' => null, 'bootosID' => $b->getID(), 'visible' => '1'));
+ if(Pbs_Acl::checkRight('cc')){
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $b->getGroupID(), 'membershipID' => null, 'bootosID' => $b->getID()));
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $groupID, 'membershipID' => null, 'bootosID' => $b->getID()));
+ }else{
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $b->getGroupID(), 'membershipID' => null, 'bootosID' => $b->getID(), 'visible' => '1'));
+ $this->view->configlist[$b->getID()] = $this->configMapper->findBy(array('groupID' => $groupID, 'membershipID' => null, 'bootosID' => $b->getID(), 'visible' => '1'));
+ }
foreach ($this->view->configlist[$b->getID()] as $config){
$config->setCreated(date(Zend_Registry::get('dateformat'),$config->getCreated()));
}