Correction pour passer dans la recherche giant après enregistrement de la session
This commit is contained in:
parent
596497fd6e
commit
200a4a8a9f
@ -137,14 +137,20 @@ class RechercheController extends Zend_Controller_Action
|
||||
$request = $this->getRequest();
|
||||
$params = $request->getParams();
|
||||
|
||||
//Giant
|
||||
$pays = $request->getParam('pays');
|
||||
if( !empty($pays) )
|
||||
$this->_forward('index', 'giant');
|
||||
|
||||
$type = $request->getParam('type', '');
|
||||
|
||||
$rechercheParams = new RechercheHistorique();
|
||||
if (count($rechercheParams->liste())>0){
|
||||
$recherche = $rechercheParams->item(0);
|
||||
$type = $recherche['type'];
|
||||
$params = $recherche['params'];
|
||||
}
|
||||
|
||||
//Giant
|
||||
if( isset($params['pays']) && !empty($params['pays']) ){
|
||||
$this->_forward('index', 'giant');
|
||||
}
|
||||
|
||||
$rechercheParams = new RechercheHistorique();
|
||||
//Si le formulaire a été soumis alors on enregistre en session et on redirige
|
||||
if ($request->isPost() && !empty($type)) {
|
||||
$rechercheParams->save($type, $params);
|
||||
@ -152,10 +158,6 @@ class RechercheController extends Zend_Controller_Action
|
||||
}
|
||||
|
||||
$page = $request->getParam('page', 1);
|
||||
|
||||
$recherche = $rechercheParams->item(0);
|
||||
$type = $recherche['type'];
|
||||
$params = $recherche['params'];
|
||||
|
||||
//Criteres recherche entreprise
|
||||
if ($type=='ent'){
|
||||
@ -350,7 +352,7 @@ class RechercheController extends Zend_Controller_Action
|
||||
} else {
|
||||
$this->view->assign('blockDirToEntreprise', false);
|
||||
}
|
||||
|
||||
|
||||
$this->view->assign('liste', $liste);
|
||||
$this->view->assign('totPage', $totPage);
|
||||
$this->view->assign('curPage', $curPage);
|
||||
|
Loading…
x
Reference in New Issue
Block a user