"._("autorisation"); if(!isset($premier)) $premier=''; if(!isset($recherche1)) $recherche1=''; if(!isset($tricolsf)) $tricolsf=''; if(!isset($premiersf)) $premiersf=''; if(!isset($selection)) $selection=''; if(!isset($retourformulaire)) $retourformulaire=''; if (isset($idx) && $idx != ']' && trim($idx) != '') { $ent .= "-> ".$idx." "; } if (isset($idz) && trim($idz) != '') { $ent .= " ".strtoupper($idz)." "; } // FROM $table = DB_PREFIXE."autorisation LEFT JOIN ".DB_PREFIXE."emplacement ON autorisation.emplacement=emplacement.emplacement LEFT JOIN ".DB_PREFIXE."titre_de_civilite ON autorisation.titre=titre_de_civilite.titre_de_civilite "; // SELECT $champAffiche = array( 'autorisation.autorisation as "'._("autorisation").'"', 'emplacement.nature as "'._("emplacement").'"', 'autorisation.nature as "'._("nature").'"', 'titre_de_civilite.libelle as "'._("titre").'"', 'autorisation.nom as "'._("nom").'"', 'autorisation.marital as "'._("marital").'"', 'autorisation.prenom as "'._("prenom").'"', 'to_char(autorisation.datenaissance ,\'DD/MM/YYYY\') as "'._("datenaissance").'"', 'autorisation.adresse1 as "'._("adresse1").'"', 'autorisation.adresse2 as "'._("adresse2").'"', 'autorisation.cp as "'._("cp").'"', 'autorisation.ville as "'._("ville").'"', 'autorisation.telephone as "'._("telephone").'"', "case autorisation.dcd when 't' then 'Oui' else 'Non' end as \""._("dcd")."\"", 'autorisation.parente as "'._("parente").'"', ); // $champNonAffiche = array( 'autorisation.observation as "'._("observation").'"', ); // $champRecherche = array( 'autorisation.autorisation as "'._("autorisation").'"', 'emplacement.nature as "'._("emplacement").'"', 'autorisation.nature as "'._("nature").'"', 'titre_de_civilite.libelle as "'._("titre").'"', 'autorisation.nom as "'._("nom").'"', 'autorisation.marital as "'._("marital").'"', 'autorisation.prenom as "'._("prenom").'"', 'autorisation.adresse1 as "'._("adresse1").'"', 'autorisation.adresse2 as "'._("adresse2").'"', 'autorisation.cp as "'._("cp").'"', 'autorisation.ville as "'._("ville").'"', 'autorisation.telephone as "'._("telephone").'"', 'autorisation.parente as "'._("parente").'"', ); $tri="ORDER BY emplacement.nature ASC NULLS LAST"; $edition="autorisation"; /** * Gestion de la clause WHERE => $selection */ // Filtre listing standard $selection = ""; // Liste des clés étrangères avec leurs éventuelles surcharges $foreign_keys_extended = array( "emplacement" => array("emplacement", ), "titre_de_civilite" => array("titre_de_civilite", ), ); // Filtre listing sous formulaire - emplacement if (in_array($retourformulaire, $foreign_keys_extended["emplacement"])) { $selection = " WHERE (autorisation.emplacement = '".$idx."') "; } // Filtre listing sous formulaire - titre_de_civilite if (in_array($retourformulaire, $foreign_keys_extended["titre_de_civilite"])) { $selection = " WHERE (autorisation.titre = '".$idx."') "; } /** * Gestion SOUSFORMULAIRE => $sousformulaire */ $sousformulaire = array( 'courrier', ); ?>