예제 #1
0
 public function update()
 {
     $user = User::findById($this->params['id']);
     if ($user->updateAttributes($this->params['user'])) {
         $this->redirect(playerPath($user->id), "User updated");
     } else {
         $this->view->user = $user;
         $this->view->render('Players/edit');
     }
 }