summaryrefslogtreecommitdiffstats
path: root/application/modules/user/controllers/ClientController.php
diff options
context:
space:
mode:
authorSimon2011-04-29 10:18:39 +0200
committerSimon2011-04-29 10:18:39 +0200
commitb87c06378211d1f6b01793148617bbf7861a2c4f (patch)
tree1f32de7872b505d1dce1fce53be3039e4cc76521 /application/modules/user/controllers/ClientController.php
parentfreeclients werden direkt mit sql gesucht (diff)
downloadpbs2-b87c06378211d1f6b01793148617bbf7861a2c4f.tar.gz
pbs2-b87c06378211d1f6b01793148617bbf7861a2c4f.tar.xz
pbs2-b87c06378211d1f6b01793148617bbf7861a2c4f.zip
Paar Mapper angepasst
Diffstat (limited to 'application/modules/user/controllers/ClientController.php')
-rw-r--r--application/modules/user/controllers/ClientController.php25
1 files changed, 8 insertions, 17 deletions
diff --git a/application/modules/user/controllers/ClientController.php b/application/modules/user/controllers/ClientController.php
index 589fcdc..76419a8 100644
--- a/application/modules/user/controllers/ClientController.php
+++ b/application/modules/user/controllers/ClientController.php
@@ -77,10 +77,10 @@ class User_ClientController extends Zend_Controller_Action
// Pagination
$pagination = new Pbs_Pagination();
- $pagination->setPerPage(10);
- $pagination->setElement($clientsInGroup);
- $pagination->setRequestPage($this->_request->getParam('page'));
- $pagination->setPageUrl('/user/client/index'.((isset($this->view->search))?'/search/'.$this->view->search:''));
+ $pagination->setPerPage(10)
+ ->setElement($clientsInGroup)
+ ->setRequestPage($this->_request->getParam('page'))
+ ->setPageUrl('/user/client/index'.((isset($this->view->search))?'/search/'.$this->view->search:''));
$clientsInGroup = $pagination->getElements();
$this->view->pagination = $pagination->pagination();
@@ -115,10 +115,10 @@ class User_ClientController extends Zend_Controller_Action
$client = new Application_Model_Client($_POST);
$mac = ($mac!='')?$mac:$_POST['macadress'];
$hh = ($hh!='')?$hh:$_POST['hardwarehash'];
- $client->setMacadress($mac);
- $client->setHardwarehash($hh);
- $client->setCreated(time());
- $client->setGroupID($this->membership->getGroupID());
+ $client->setMacadress($mac)
+ ->setHardwarehash($hh)
+ ->setCreated(time())
+ ->setGroupID($this->membership->getGroupID());
$clientmapper = new Application_Model_ClientMapper();
$clientmapper->save($client);
$this->_redirect('/user/client/index/addresult/ok');
@@ -200,13 +200,4 @@ class User_ClientController extends Zend_Controller_Action
$this->view->editclient = $editclient;
}
}
-
-
}
-
-
-
-
-
-
-