Esempio n. 1
0
 public function updateAction()
 {
     if ($this->getRequest()->isPost()) {
         $this->userService->SaveUser($this->_getParam('id'), $this->_getParam('name'), $this->_getParam('email'));
         $this->_redirect('index');
     } else {
         $this->view->user = $this->userService->GetUser($this->_getParam('id'))->current();
     }
 }
Esempio n. 2
0
 public function associateAction()
 {
     $tasks = $this->userService->GetAllTasks();
     $this->view->user = $this->userService->GetUser($this->_getParam('id'));
     $this->view->form = new App_forms_Associate($this->view->user, $tasks);
     if ($this->getRequest()->isPost() && $this->view->form->isValid($this->getRequest()->getParams())) {
         $this->view->form->persistData();
     }
 }