public function editAction()
 {
     $form = $this->formManager->initForm('userEditForm', dirname(__FILE__) . '/userForm.xml');
     $form->setUnicityValidator('user', $this->userDao);
     $new = false;
     if ($form->isSubmit()) {
         if ($form->isValid()) {
             $user = $form->getContainer('user');
             $this->userService->save($user);
             $this->goHome();
             return;
         }
     } else {
         if ($this->userProfil->isConnected()) {
             $user = clone $this->userProfil->getCurrentUser();
             // if not cloned, we edit directly the currentuser
         } else {
             $user = new \org\equinox\modules\user\dao\UserDto();
             $new = true;
         }
         $form->setContainer('user', $user);
     }
     // Mandatory : this store the original object in session to retrieve after update by the form
     $this->formManager->storeForm($form);
     $this->assign('definition', $form);
     $this->assign('form', $form);
     $this->assign('new', $new);
 }
 public function headerAction()
 {
     $this->assign('titles', $this->getTitleCurrentPage());
     $this->assign('url', $this->userProfil->getUrlLastPage());
 }