Subversion Repositories eFlore/Applications.eflore-consultation

Rev

Rev 216 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 216 Rev 245
Line 64... Line 64...
64
		$form = I18n::get('Recherche-form-nom');
64
		$form = I18n::get('Recherche-form-nom');
65
		if ($res == false || $res['entete']['total'] == 0) { // recherche nom approché
65
		if ($res == false || $res['entete']['total'] == 0) { // recherche nom approché
66
			$approche = $this->rechercherNomApproche($noms);
66
			$approche = $this->rechercherNomApproche($noms);
67
		} elseif ($res['entete']['total'] == 1 || $this->submit == $form['fiche']) { // renvoie à la fiche
67
		} elseif ($res['entete']['total'] == 1 || $this->submit == $form['fiche']) { // renvoie à la fiche
68
			$ids = array_keys($res['resultat']);
68
			$ids = array_keys($res['resultat']);
69
			$url = $this->urls->obtenirUrlFiche($ids[0], $this->type_nom, $this->nom);
69
			$url = $this->urls->obtenirUrlFiche($ids[0], $this->type_nom, $this->nom, $res['resultat'][$ids[0]][nom_sci]);
70
			$this->redirigerVers($url);
70
			$this->redirigerVers($url);
71
		} else { // affiche les résultats
71
		} else { // affiche les résultats
72
			$res['type'] = $this->type_nom;
72
			$res['type'] = $this->type_nom;
73
			Registre::set('resultats', $res);
73
			Registre::set('resultats', $res);
74
			$approche = 'ok';
74
			$approche = 'ok';