From b791d541a6ace61cbbe1d12838b98ae30743d1b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20M=C3=BCller?= Date: Sun, 11 May 2014 15:40:33 +0200 Subject: [PATCH] password --- app/Controller/RegistrationController.php | 3 ++- app/Controller/SearchController.php | 1 - 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Controller/RegistrationController.php b/app/Controller/RegistrationController.php index 8f3f19f..b084613 100644 --- a/app/Controller/RegistrationController.php +++ b/app/Controller/RegistrationController.php @@ -161,6 +161,7 @@ class RegistrationController extends AppController { if ($result) { $this->MiconwareSession->setFlash(__('dreamjob.password_reset.send'), 'flash', array('alert' => 'success')); + return $this->redirect(array('controller'=>'home','action' => 'home')); } else { $this->MiconwareSession->setFlash(__('dreamjob.password_reset.send.error'), 'flash', array('alert' => 'danger')); } @@ -185,10 +186,10 @@ class RegistrationController extends AppController { if (!$send and $this->request->is('post')) { if ($this->request->data['User']['password1'] == $this->request->data['User']['password2']) { $password = $this->MiconwareSession->create_hash($this->request->data['User']['password1']); - var_dump($password); $result = $this->User->replace_password($try,$password); if ($result) { $this->MiconwareSession->setFlash(__('dreamjob.password_replace.done'), 'flash', array('alert' => 'success')); + return $this->redirect(array('controller'=>'home','action' => 'home')); } else { $this->MiconwareSession->setFlash(__('dreamjob.password_replace.error'), 'flash', array('alert' => 'danger')); } diff --git a/app/Controller/SearchController.php b/app/Controller/SearchController.php index acd47ec..4704ba8 100644 --- a/app/Controller/SearchController.php +++ b/app/Controller/SearchController.php @@ -181,7 +181,6 @@ class SearchController extends AppController { $c[] = $b['DreamjobISearch']['worker_id']; $con['DreamjobWorker.djaccount_ptr_id'] =$c; } - var_dump($con); $workers = $this->DreamjobWorker->find('all', array('conditions' => $con)); $this->set("workers", $workers);