12,6 → 12,8 |
private $param; |
private $i18n = array(); |
|
private $parametresAvancesGeneriques = array('gen','fam','nn','nt','sp','ssp','type','sto','sti','stc'); |
|
public function initialiser() { |
$this->capturerParametres(); |
$this->capturerParametresAvances(); |
201,58 → 203,59 |
} |
|
private function capturerParametresAvances() { |
if (isset($_GET['gen']) && $_GET['gen'] != '') { |
$this->param['gen'] = $this->convertirEncodageEntree(urldecode($_GET['gen'])); |
$this->capturerParametresAvancesGeneriques(); |
$this->capturerParametresAvancesDependantsLangage(); |
$this->capturerParametresAvancesPresenceSpecifiques(); |
} |
|
private function capturerParametresAvancesGeneriques() { |
foreach($this->parametresAvancesGeneriques as $param) { |
if (isset($_GET[$param]) && $_GET[$param] != '') { |
$this->param[$param] = $this->convertirEncodageEntree(urldecode($_GET[$param])); |
} |
} |
if (isset($_GET['fam']) && $_GET['fam'] != '') { |
$this->param['fam'] = $this->convertirEncodageEntree(urldecode($_GET['fam'])); |
} |
if (isset($_GET['au']) && $_GET['au'] != '' |
&& $_GET['au'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-auteur']))) { |
} |
|
private function capturerParametresAvancesDependantsLangage() { |
if (isset($_GET['au']) && $_GET['au'] != '' |
&& $_GET['au'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-auteur']))) { |
$this->param['au'] = $this->convertirEncodageEntree(urldecode($_GET['au'])); |
} |
if (isset($_GET['bib']) && $_GET['bib'] != '' |
&& $_GET['bib'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-bib']))) { |
&& $_GET['bib'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-bib']))) { |
$this->param['bib'] = $this->convertirEncodageEntree(urldecode($_GET['bib'])); |
} |
if (isset($_GET['nn']) && $_GET['nn'] != '') { |
$this->param['nn'] = $this->convertirEncodageEntree(urldecode($_GET['nn'])); |
} |
if (isset($_GET['nt']) && $_GET['nt'] != '') { |
$this->param['nt'] = $this->convertirEncodageEntree(urldecode($_GET['nt'])); |
} |
if (isset($_GET['sp']) && $_GET['sp'] != '') { |
$this->param['sp'] = $this->convertirEncodageEntree(urldecode($_GET['sp'])); |
} |
if (isset($_GET['ssp']) && $_GET['ssp'] != '') { |
$this->param['ssp'] = $this->convertirEncodageEntree(urldecode($_GET['ssp'])); |
} |
if (isset($_GET['type']) && $_GET['type'] != '') { |
$this->param['type'] = $this->convertirEncodageEntree(urldecode($_GET['type'])); |
} |
if (isset($_GET['and']) && $_GET['and'] != '' |
&& $_GET['and'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-date']))) { |
&& $_GET['and'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-date']))) { |
$this->param['and'] = $this->convertirEncodageEntree(urldecode($_GET['and'])); |
} |
if (isset($_GET['anf']) && $_GET['anf'] != '' |
&& $_GET['anf'] != $this->convertirEncodageEntree(urlencode($this->i18n['valeur-form-date']))) { |
&& $_GET['anf'] != urlencode($this->i18n['valeur-form-date'])) { |
$this->param['anf'] = $this->convertirEncodageEntree(urldecode($_GET['anf'])); |
} |
if (isset($_GET['prga']) && $_GET['prga'] != '') { |
$this->param['prga'] = $this->convertirEncodageEntree(urldecode($_GET['prga'])); |
} |
|
private function capturerParametresAvancesPresenceSpecifiques() { |
$champs_presence = $this->obtenirChampsPresence(); |
foreach($champs_presence as $champ) { |
$param = $champ['param']; |
if (isset($_GET[$param]) && $_GET[$param] != '') { |
$this->param[$param] = $this->convertirEncodageEntree(urldecode($_GET[$param])); |
} |
} |
if (isset($_GET['prco']) && $_GET['prco'] != '') { |
$this->param['prco'] = $this->convertirEncodageEntree(urldecode($_GET['prco'])); |
} |
|
private function obtenirChampsPresence() { |
$tableau_champs_presence = array(); |
$referentiel = Registre::get('parametres.referentiel'); |
$champs_presence = Config::get($referentiel.'.champsPresence'); |
$champs_presence_spl = explode('|', $champs_presence); |
foreach($champs_presence_spl as $champ) { |
$label_param_champ = explode(':', $champ); |
$tableau_champs_presence[] = array('param' => $label_param_champ[1], |
'label' => $label_param_champ[0]); |
} |
if (isset($_GET['sto']) && $_GET['sto'] != '') { |
$this->param['sto'] = $this->convertirEncodageEntree(urldecode($_GET['sto'])); |
} |
if (isset($_GET['sti']) && $_GET['sti'] != '') { |
$this->param['sti'] = $this->convertirEncodageEntree(urldecode($_GET['sti'])); |
} |
if (isset($_GET['stc']) && $_GET['stc'] != '') { |
$this->param['stc'] = $this->convertirEncodageEntree(urldecode($_GET['stc'])); |
} |
return $tableau_champs_presence; |
} |
|
protected function recupererTableauConfig($param) { |