예제 #1
0
 public function handleRemove()
 {
     if (($entity = $this->notificationUserRepository->find($this->id)) === null) {
         throw new BadRequestException();
     }
     $this->notificationUserRepository->delete($entity);
     $this->redirect('this');
     $this->redrawControl('content');
     $this->id = null;
 }
예제 #2
0
파일: JobControl.php 프로젝트: venne/venne
 public function handleRemove()
 {
     if (($entity = $this->jobRepository->find($this->id)) === null) {
         throw new BadRequestException();
     }
     if ($entity->user !== $this->user->identity) {
         throw new BadRequestException();
     }
     $this->jobRepository->delete($entity);
     if (!$this->presenter->isAjax()) {
         $this->redirect('this');
     }
 }
예제 #3
0
 public function registrationSuccess()
 {
     $this->invitationRepository->delete($this->invitation);
     $this->flashMessage($this->translator->translate('Your registration is complete.'), 'success');
     $this->redirect('this', array('hash' => null, 'registration' => null));
 }