diff options
Diffstat (limited to 'application/modules/user/controllers/PersonController.php')
| -rw-r--r-- | application/modules/user/controllers/PersonController.php | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/application/modules/user/controllers/PersonController.php b/application/modules/user/controllers/PersonController.php index da640ba..ba4be8e 100644 --- a/application/modules/user/controllers/PersonController.php +++ b/application/modules/user/controllers/PersonController.php @@ -34,7 +34,7 @@ class user_PersonController extends Zend_Controller_Action if (Zend_Auth::getInstance()->hasIdentity()) { $this->personmapper = new Application_Model_PersonMapper(); $this->userIDsNamespace = Zend_Session::namespaceGet('userIDs'); - if($this->userIDsNamespace['personID']) { + if(isset($this->userIDsNamespace['personID'])) { $this->person = $this->personmapper->find($this->userIDsNamespace['personID']); } else { $result = $this->personmapper->findBy(array('email' => Zend_Auth::getInstance()->getIdentity()),true); @@ -111,7 +111,7 @@ class user_PersonController extends Zend_Controller_Action $pagination->setPageUrl('/user/person/index/'.((isset($this->view->search))?'/search/'.$this->view->search:'')); $this->view->personList = $pagination->getElements(); - $this->view->pagination = $pagination->pagination($pageurl); + $this->view->pagination = $pagination->pagination(); $this->view->page = $pagination->getRequestPage(); } @@ -123,6 +123,7 @@ class user_PersonController extends Zend_Controller_Action $this->view->person = $this->person; $groupRequests = $this->groupRequestMapper->findBy(array('personID' => $this->person->getID()),true); if(isset($groupRequests)) { + $groupRequestList = array(); foreach($groupRequests as $groupRequest) { $group = $this->groupMapper->find($groupRequest['groupID']); $groupRequestList[] = array( @@ -130,7 +131,7 @@ class user_PersonController extends Zend_Controller_Action 'group' => $group ); } - if(is_array($groupRequestList)) { + if(count($groupRequestList)> 0) { $this->view->groupRequestList = $groupRequestList; } } @@ -142,7 +143,7 @@ class user_PersonController extends Zend_Controller_Action $pagination->setPageUrl('/user/person/index' .((isset($this->view->search))?'/search/'.$this->view->search:'')); $this->view->groups = $pagination->getElements(); - $this->view->pagination = $pagination->pagination($pageurl); + $this->view->pagination = $pagination->pagination(); $this->view->page = $pagination->getRequestPage(); // This should be activated in case the person has no membership and no rights. $this->view->groupRequestRight = true; @@ -235,7 +236,7 @@ class user_PersonController extends Zend_Controller_Action if($membership['groupID'] == $group->getID()) { $groupsFound[$count] = true; } else { - if($groupsFound[$count] != true) { + if(@$groupsFound[$count] != true) { $groupsFound[$count] = false; } } @@ -330,6 +331,7 @@ class user_PersonController extends Zend_Controller_Action $groupMapper = new Application_Model_GroupMapper(); $roleMapper = new Application_Model_RoleMapper(); if(isset($this->memberships)) { + $suspendlist = array(); foreach($this->memberships as $membership) { $group = $groupMapper->find($membership['groupID']); $role = $roleMapper->find($membership['roleID']); @@ -420,7 +422,7 @@ class user_PersonController extends Zend_Controller_Action $pagination->setPageUrl('/user/person/show/personID/' . $personID .((isset($this->view->search))?'/search/'.$this->view->search:'')); $this->view->groups = $pagination->getElements(); - $this->view->pagination = $pagination->pagination($pageurl); + $this->view->pagination = $pagination->pagination(); $this->view->page = $pagination->getRequestPage(); $this->view->personID = $personID; $this->view->editRight = Pbs_Acl::checkRight('peoa'); |
