1 |
fraynaud |
3 |
<?php |
2 |
|
|
//$Id$ |
3 |
|
|
//gen openMairie le 10/02/2011 20:33 |
4 |
|
|
include('../gen/sql/pgsql/evenement.form.inc.php'); |
5 |
fraynaud |
7 |
$sql_om_lettretype="select id,(id||' '||libelle) as libelle from ". |
6 |
|
|
DB_PREFIXE."om_lettretype"; |
7 |
vpihour |
1133 |
|
8 |
|
|
$sep = (isset($_GET['action']) && |
9 |
|
|
($_GET['action'] == 1 || $_GET['action'] == 0 )) ? ';' : ',' ; |
10 |
|
|
|
11 |
|
|
$champs=array( |
12 |
|
|
"evenement.evenement", |
13 |
|
|
"libelle", |
14 |
|
|
"nature", |
15 |
|
|
"action", |
16 |
|
|
"etat", |
17 |
|
|
"delai", |
18 |
|
|
"accord_tacite", |
19 |
|
|
"delai_notification", |
20 |
|
|
"lettretype", |
21 |
|
|
"consultation", |
22 |
|
|
"avis_decision", |
23 |
|
|
"restriction", |
24 |
|
|
"type", |
25 |
|
|
"evenement_retour_ar", |
26 |
|
|
"evenement_suivant_tacite", |
27 |
|
|
"array_to_string(array_agg(dossier_instruction_type ORDER BY dossier_instruction_type), '$sep') as dossier_instruction_type"); |
28 |
|
|
|
29 |
|
|
$tableSelect = DB_PREFIXE."evenement |
30 |
|
|
LEFT JOIN |
31 |
|
|
".DB_PREFIXE."lien_dossier_instruction_type_evenement |
32 |
|
|
ON |
33 |
|
|
lien_dossier_instruction_type_evenement.evenement=evenement.evenement"; |
34 |
|
|
|
35 |
|
|
$selection = " GROUP BY evenement.evenement,libelle"; |
36 |
|
|
|
37 |
|
|
$sql_dossier_instruction_type="SELECT |
38 |
|
|
dossier_instruction_type.dossier_instruction_type, |
39 |
|
|
CONCAT( dossier_instruction_type.code ,' - ',dossier_instruction_type.libelle) |
40 |
|
|
FROM |
41 |
|
|
".DB_PREFIXE."dossier_instruction_type |
42 |
|
|
ORDER BY |
43 |
|
|
dossier_instruction_type.libelle"; |
44 |
|
|
$sql_dossier_instruction_type_by_id = "SELECT |
45 |
|
|
dossier_instruction_type.dossier_instruction_type, |
46 |
|
|
CONCAT( dossier_instruction_type.code ,' - ',dossier_instruction_type.libelle) |
47 |
|
|
FROM |
48 |
|
|
".DB_PREFIXE."dossier_instruction_type |
49 |
|
|
WHERE |
50 |
|
|
dossier_instruction_type IN (<idx>) |
51 |
|
|
ORDER BY |
52 |
|
|
dossier_instruction_type.libelle"; |
53 |
fraynaud |
3 |
?> |