| Line 10... |
Line 10... |
| 10 |
protected $acces_fiche = false;
|
10 |
protected $acces_fiche = false;
|
| 11 |
private $recherche_avancee;
|
11 |
private $recherche_avancee;
|
| 12 |
private $param;
|
12 |
private $param;
|
| 13 |
private $i18n = array();
|
13 |
private $i18n = array();
|
| Line -... |
Line 14... |
| - |
|
14 |
|
| - |
|
15 |
private $parametresAvancesGeneriques = array('gen','fam','nn','nt','sp','ssp','type','sto','sti','stc');
|
| 14 |
|
16 |
|
| 15 |
public function initialiser() {
|
17 |
public function initialiser() {
|
| 16 |
$this->capturerParametres();
|
18 |
$this->capturerParametres();
|
| 17 |
$this->capturerParametresAvances();
|
19 |
$this->capturerParametresAvances();
|
| 18 |
$this->i18n = I18n::get('Recherche-form-avancee');
|
20 |
$this->i18n = I18n::get('Recherche-form-avancee');
|
| Line 199... |
Line 201... |
| 199 |
$this->type_resultat = $onglet_resultat[Registre::get('parametres.niveau').'_'.$this->type_nom];
|
201 |
$this->type_resultat = $onglet_resultat[Registre::get('parametres.niveau').'_'.$this->type_nom];
|
| 200 |
}
|
202 |
}
|
| 201 |
}
|
203 |
}
|
| Line 202... |
Line 204... |
| 202 |
|
204 |
|
| 203 |
private function capturerParametresAvances() {
|
205 |
private function capturerParametresAvances() {
|
| - |
|
206 |
$this->capturerParametresAvancesGeneriques();
|
| 204 |
if (isset($_GET['gen']) && $_GET['gen'] != '') {
|
207 |
$this->capturerParametresAvancesDependantsLangage();
|
| 205 |
$this->param['gen'] = $this->convertirEncodageEntree(urldecode($_GET['gen']));
|
208 |
$this->capturerParametresAvancesPresenceSpecifiques();
|
| - |
|
209 |
}
|
| - |
|
210 |
|
| - |
|
211 |
private function capturerParametresAvancesGeneriques() {
|
| 206 |
}
|
212 |
foreach($this->parametresAvancesGeneriques as $param) {
|
| 207 |
if (isset($_GET['fam']) && $_GET['fam'] != '') {
|
213 |
if (isset($_GET[$param]) && $_GET[$param] != '') {
|
| - |
|
214 |
$this->param[$param] = $this->convertirEncodageEntree(urldecode($_GET[$param]));
|
| 208 |
$this->param['fam'] = $this->convertirEncodageEntree(urldecode($_GET['fam']));
|
215 |
}
|
| - |
|
216 |
}
|
| - |
|
217 |
}
|
| - |
|
218 |
|
| 209 |
}
|
219 |
private function capturerParametresAvancesDependantsLangage() {
|
| 210 |
if (isset($_GET['au']) && $_GET['au'] != ''
|
220 |
if (isset($_GET['au']) && $_GET['au'] != ''
|
| 211 |
&& $_GET['au'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-auteur']))) {
|
221 |
&& $_GET['au'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-auteur']))) {
|
| 212 |
$this->param['au'] = $this->convertirEncodageEntree(urldecode($_GET['au']));
|
222 |
$this->param['au'] = $this->convertirEncodageEntree(urldecode($_GET['au']));
|
| 213 |
}
|
223 |
}
|
| 214 |
if (isset($_GET['bib']) && $_GET['bib'] != ''
|
224 |
if (isset($_GET['bib']) && $_GET['bib'] != ''
|
| 215 |
&& $_GET['bib'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-bib']))) {
|
225 |
&& $_GET['bib'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-bib']))) {
|
| 216 |
$this->param['bib'] = $this->convertirEncodageEntree(urldecode($_GET['bib']));
|
226 |
$this->param['bib'] = $this->convertirEncodageEntree(urldecode($_GET['bib']));
|
| 217 |
}
|
- |
|
| 218 |
if (isset($_GET['nn']) && $_GET['nn'] != '') {
|
- |
|
| 219 |
$this->param['nn'] = $this->convertirEncodageEntree(urldecode($_GET['nn']));
|
- |
|
| 220 |
}
|
- |
|
| 221 |
if (isset($_GET['nt']) && $_GET['nt'] != '') {
|
- |
|
| 222 |
$this->param['nt'] = $this->convertirEncodageEntree(urldecode($_GET['nt']));
|
- |
|
| 223 |
}
|
- |
|
| 224 |
if (isset($_GET['sp']) && $_GET['sp'] != '') {
|
- |
|
| 225 |
$this->param['sp'] = $this->convertirEncodageEntree(urldecode($_GET['sp']));
|
- |
|
| 226 |
}
|
- |
|
| 227 |
if (isset($_GET['ssp']) && $_GET['ssp'] != '') {
|
- |
|
| 228 |
$this->param['ssp'] = $this->convertirEncodageEntree(urldecode($_GET['ssp']));
|
- |
|
| 229 |
}
|
- |
|
| 230 |
if (isset($_GET['type']) && $_GET['type'] != '') {
|
- |
|
| 231 |
$this->param['type'] = $this->convertirEncodageEntree(urldecode($_GET['type']));
|
- |
|
| 232 |
}
|
227 |
}
|
| 233 |
if (isset($_GET['and']) && $_GET['and'] != ''
|
228 |
if (isset($_GET['and']) && $_GET['and'] != ''
|
| 234 |
&& $_GET['and'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-date']))) {
|
229 |
&& $_GET['and'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-date']))) {
|
| 235 |
$this->param['and'] = $this->convertirEncodageEntree(urldecode($_GET['and']));
|
230 |
$this->param['and'] = $this->convertirEncodageEntree(urldecode($_GET['and']));
|
| 236 |
}
|
231 |
}
|
| 237 |
if (isset($_GET['anf']) && $_GET['anf'] != ''
|
232 |
if (isset($_GET['anf']) && $_GET['anf'] != ''
|
| 238 |
&& $_GET['anf'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-date']))) {
|
233 |
&& $_GET['anf'] != urlencode($this->i18n['valeur-form-date'])) {
|
| 239 |
$this->param['anf'] = $this->convertirEncodageEntree(urldecode($_GET['anf']));
|
234 |
$this->param['anf'] = $this->convertirEncodageEntree(urldecode($_GET['anf']));
|
| 240 |
}
|
- |
|
| 241 |
if (isset($_GET['prga']) && $_GET['prga'] != '') {
|
- |
|
| 242 |
$this->param['prga'] = $this->convertirEncodageEntree(urldecode($_GET['prga']));
|
235 |
}
|
| - |
|
236 |
}
|
| 243 |
}
|
237 |
|
| 244 |
if (isset($_GET['prco']) && $_GET['prco'] != '') {
|
238 |
private function capturerParametresAvancesPresenceSpecifiques() {
|
| - |
|
239 |
$champs_presence = $this->obtenirChampsPresence();
|
| 245 |
$this->param['prco'] = $this->convertirEncodageEntree(urldecode($_GET['prco']));
|
240 |
foreach($champs_presence as $champ) {
|
| 246 |
}
|
241 |
$param = $champ['param'];
|
| 247 |
if (isset($_GET['sto']) && $_GET['sto'] != '') {
|
242 |
if (isset($_GET[$param]) && $_GET[$param] != '') {
|
| 248 |
$this->param['sto'] = $this->convertirEncodageEntree(urldecode($_GET['sto']));
|
243 |
$this->param[$param] = $this->convertirEncodageEntree(urldecode($_GET[$param]));
|
| 249 |
}
|
- |
|
| 250 |
if (isset($_GET['sti']) && $_GET['sti'] != '') {
|
- |
|
| 251 |
$this->param['sti'] = $this->convertirEncodageEntree(urldecode($_GET['sti']));
|
244 |
}
|
| - |
|
245 |
}
|
| - |
|
246 |
}
|
| - |
|
247 |
|
| - |
|
248 |
private function obtenirChampsPresence() {
|
| - |
|
249 |
$tableau_champs_presence = array();
|
| - |
|
250 |
$referentiel = Registre::get('parametres.referentiel');
|
| - |
|
251 |
$champs_presence = Config::get($referentiel.'.champsPresence');
|
| 252 |
}
|
252 |
$champs_presence_spl = explode('|', $champs_presence);
|
| - |
|
253 |
foreach($champs_presence_spl as $champ) {
|
| 253 |
if (isset($_GET['stc']) && $_GET['stc'] != '') {
|
254 |
$label_param_champ = explode(':', $champ);
|
| - |
|
255 |
$tableau_champs_presence[] = array('param' => $label_param_champ[1],
|
| 254 |
$this->param['stc'] = $this->convertirEncodageEntree(urldecode($_GET['stc']));
|
256 |
'label' => $label_param_champ[0]);
|
| - |
|
257 |
}
|
| 255 |
}
|
258 |
return $tableau_champs_presence;
|
| Line 256... |
Line 259... |
| 256 |
}
|
259 |
}
|
| 257 |
|
260 |
|
| 258 |
protected function recupererTableauConfig($param) {
|
261 |
protected function recupererTableauConfig($param) {
|