diff options
| author | Björn Geiger | 2011-04-05 17:36:08 +0200 |
|---|---|---|
| committer | Björn Geiger | 2011-04-05 17:36:08 +0200 |
| commit | 58dfe1b55ef3ead11117e19b4abb84c6b83814c1 (patch) | |
| tree | a6f253d0c939f64628bb87ad280ad6f68b7f9c3f /application/modules/user/controllers/RoleController.php | |
| parent | Merge branch 'master' of ssh://git.openslx.org/lsfks/master-teamprojekt/pbs2 (diff) | |
| download | pbs2-58dfe1b55ef3ead11117e19b4abb84c6b83814c1.tar.gz pbs2-58dfe1b55ef3ead11117e19b4abb84c6b83814c1.tar.xz pbs2-58dfe1b55ef3ead11117e19b4abb84c6b83814c1.zip | |
Paging bei Person, Group und Role
Diffstat (limited to 'application/modules/user/controllers/RoleController.php')
| -rw-r--r-- | application/modules/user/controllers/RoleController.php | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/application/modules/user/controllers/RoleController.php b/application/modules/user/controllers/RoleController.php index 38c12b0..86872f0 100644 --- a/application/modules/user/controllers/RoleController.php +++ b/application/modules/user/controllers/RoleController.php @@ -23,8 +23,16 @@ class User_RoleController extends Zend_Controller_Action public function indexAction() { if(isset($this->userIDsNamespace['groupID'])) { - $roleList = $this->roleMapper->findBy(array('groupID' => $this->userIDsNamespace['groupID']),true); - $this->view->roleList = $roleList; + // Pagination + $pagination = new Pbs_Pagination(); + $pagination->setPerPage(5); + $pagination->setElement($this->roleMapper->findBy(array('groupID' => $this->userIDsNamespace['groupID']),true)); + $pagination->setRequestPage($this->_request->getParam('page')); + $pagination->setPageUrl('/user/role/index'.((isset($this->view->search))?'/search/'.$this->view->search:'')); + + $this->view->roleList = $pagination->getElements(); + $this->view->pagination = $pagination->pagination($pageurl); + $this->view->page = $pagination->getRequestPage(); $this->view->userIDsNamespace = $this->userIDsNamespace; } else { $this->_helper->redirector('selectmembership', 'person'); |
