/[openfoncier]/trunk/sql/pgsql/dossier.inc.php
ViewVC logotype

Contents of /trunk/sql/pgsql/dossier.inc.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1485 - (show annotations)
Mon Mar 18 01:11:59 2013 UTC (11 years, 10 months ago) by fmichon
File size: 8321 byte(s)
Déplacement des onglets données techniques et rapport d'instruction dans le portlet en popup

1 <?php
2 //$Id$
3 //gen openMairie le 10/02/2011 20:39
4 include('../gen/sql/pgsql/dossier.inc.php');
5
6 /*Tables sur lesquels la requête va s'effectuer*/
7 $table = DB_PREFIXE."dossier
8 LEFT JOIN ".DB_PREFIXE."lien_dossier_demandeur
9 ON lien_dossier_demandeur.dossier=dossier.dossier
10 AND lien_dossier_demandeur.petitionnaire_principal IS TRUE
11 LEFT JOIN ".DB_PREFIXE."demandeur
12 ON lien_dossier_demandeur.demandeur=demandeur.demandeur
13 LEFT JOIN ".DB_PREFIXE."instructeur
14 ON dossier.instructeur = instructeur.instructeur
15 LEFT JOIN ".DB_PREFIXE."om_utilisateur
16 ON instructeur.om_utilisateur = om_utilisateur.om_utilisateur
17 LEFT JOIN ".DB_PREFIXE."avis_decision
18 ON avis_decision.avis_decision=dossier.avis_decision
19 LEFT JOIN ".DB_PREFIXE."division
20 ON dossier.division=division.division";
21
22 /*Champs du début de la requête*/
23 $champAffiche=array(
24 'dossier.dossier as "'._("dossier").'"',
25 'TRIM(CONCAT(personne_morale_denomination,\' \',personne_morale_nom,\' \',demandeur.particulier_nom)) as "'._("petitionaire").'"',
26 'instructeur.nom as "'._("instructeur").'"',
27 'to_char(dossier.date_demande ,\'DD/MM/YYYY\') as "'._("date_demande").'"',
28 'to_char(dossier.date_depot ,\'DD/MM/YYYY\') as "'._("date_depot").'"',
29 'to_char(dossier.date_complet ,\'DD/MM/YYYY\') as "'._("date_complet").'"',
30 'to_char(dossier.date_notification_delai ,\'DD/MM/YYYY\') as "'._("date_notification_delai").'"',
31 'to_char(dossier.date_limite ,\'DD/MM/YYYY\') as "'._("date_limite").'"',
32 'etat as "'._("etat").'"',
33 'avis_decision.libelle as "'._("avis_decision").'"',
34 'CASE WHEN dossier.enjeu_erp is TRUE THEN \'<span class="om-icon om-icon-16 om-icon-fix enjeu_erp-16" title="'._('Enjeu ERP').'">ERP</span>\' ELSE \'\' END ||
35 CASE WHEN dossier.enjeu_urba is TRUE THEN \'<span class="om-icon om-icon-16 om-icon-fix enjeu_urba-16" title="'._('Enjeu Urba').'">URBA</span>\' ELSE \'\' END
36 as "'._("enjeu").'"',
37 );
38
39 /*Tri*/
40 $tri= "order by dossier.dossier";
41
42 /*Recherche simple*/
43 $champRecherche=array( 'dossier.dossier as "'._("dossier").'"',
44 'personne_morale_denomination as "'._("personne_morale_denomination").'"',
45 'particulier_nom as "'._("particulier_nom").'"',
46 );
47
48 /*Icone*/
49 $ico = "../img/ico_dossier.png";
50
51 $edition="";
52
53 /*Si l'on se trouve dans le formulaire dossier_instruction*/
54 if (isset($_GET["obj"]) && $_GET["obj"] == "dossier_instruction") {
55 // Configuration de la recherche avancee
56 if (!isset($options)) {
57 $options = array();
58 }
59 // Options pour les select de faux booléens
60 $args = array(
61 0 => array("", "Oui", "Non", ),
62 1 => array(_("choisir")." "._("accord_tacite"), _("Oui"), _("Non"), ),
63 );
64 /*Champs pour la recherche avancée*/
65 $champs['dossier'] = array(
66 'table' => 'dossier',
67 'colonne' => 'dossier',
68 'type' => 'text',
69 'taille' => 30,
70 'libelle' => _('dossier'));
71 //
72 $champs['dossier_autorisation_type_detaille'] = array(
73 'table' => 'dossier_autorisation_type_detaille',
74 'colonne' => 'dossier_autorisation_type_detaille',
75 'type' => 'select',
76 'taille' => 30,
77 'libelle' => _('dossier_autorisation_type_detaille'));
78
79 //
80 $champs['parcelle'] = array(
81 'table' => 'dossier',
82 'colonne' => 'parcelle',
83 'type' => 'text',
84 'taille' => 30,
85 'libelle' => _('parcelle'));
86 //// COL2
87
88 //
89 $champs['etat'] = array(
90 'table' => 'dossier',
91 'colonne' => 'etat',
92 'type' => 'select',
93 'libelle' => _('etat'));
94 //
95 $champs['accord_tacite'] = array(
96 'table' => 'dossier',
97 'colonne' => 'accord_tacite',
98 'type' => 'select',
99 "subtype" => "manualselect",
100 'libelle' => _('accord_tacite'),
101 "args" => $args,
102 );
103
104 //// COL3
105
106
107
108
109 //
110 $champs['instructeur'] = array(
111 'table' => 'dossier',
112 'colonne' => 'instructeur',
113 'type' => 'select',
114 'libelle' => _('instructeur'));
115 //
116 //$champs['architecte'] = array(
117 // 'table' => 'dossier',
118 // 'colonne' => 'architecte',
119 // 'type' => 'select',
120 // 'libelle' => _('architecte'));
121
122 //
123 $champs['date_depot'] = array(
124 'colonne' => 'date_depot',
125 'table' => 'dossier',
126 'libelle' => _('date_depot'),
127 'lib1'=> _("debut"),
128 'lib2' => _("fin"),
129 'type' => 'date',
130 'taille' => 8,
131 'where' => 'intervaldate');
132 //
133 $champs['date_rejet'] = array(
134 'colonne' => 'date_rejet',
135 'table' => 'dossier',
136 'libelle' => _('date_rejet'),
137 'lib1'=> _("debut"),
138 'lib2' => _("fin"),
139 'type' => 'date',
140 'taille' => 8,
141 'where' => 'intervaldate');
142
143 //
144 $champs['date_validite'] = array(
145 'colonne' => 'date_validite',
146 'table' => 'dossier',
147 'libelle' => _('date_validite'),
148 'lib1'=> _("debut"),
149 'lib2' => _("fin"),
150 'type' => 'date',
151 'taille' => 8,
152 'where' => 'intervaldate');
153
154
155
156 //
157 $champs['date_complet'] = array(
158 'colonne' => 'date_complet',
159 'table' => 'dossier',
160 'libelle' => _('date_complet'),
161 'lib1'=> _("debut"),
162 'lib2' => _("fin"),
163 'type' => 'date',
164 'taille' => 8,
165 'where' => 'intervaldate');
166 //
167 $champs['date_decision'] = array(
168 'colonne' => 'date_decision',
169 'table' => 'dossier',
170 'libelle' => _('date_decision'),
171 'lib1'=> _("debut"),
172 'lib2' => _("fin"),
173 'type' => 'date',
174 'taille' => 8,
175 'where' => 'intervaldate');
176 //
177 $champs['date_limite'] = array(
178 'colonne' => 'date_limite',
179 'table' => 'dossier',
180 'libelle' => _('date_limite'),
181 'lib1'=> _("debut"),
182 'lib2' => _("fin"),
183 'type' => 'date',
184 'taille' => 8,
185 'where' => 'intervaldate');
186
187
188
189
190 //
191 $champs['date_chantier'] = array(
192 'colonne' => 'date_chantier',
193 'table' => 'dossier',
194 'libelle' => _('date_chantier'),
195 'lib1'=> _("debut"),
196 'lib2' => _("fin"),
197 'type' => 'date',
198 'taille' => 8,
199 'where' => 'intervaldate');
200 //
201 $champs['date_achevement'] = array(
202 'colonne' => 'date_achevement',
203 'table' => 'dossier',
204 'libelle' => _('date_achevement'),
205 'lib1'=> _("debut"),
206 'lib2' => _("fin"),
207 'type' => 'date',
208 'taille' => 8,
209 'where' => 'intervaldate');
210 //
211 $champs['date_conformite'] = array(
212 'colonne' => 'date_conformite',
213 'table' => 'dossier',
214 'libelle' => _('date_conformite'),
215 'lib1'=> _("debut"),
216 'lib2' => _("fin"),
217 'type' => 'date',
218 'taille' => 8,
219 'where' => 'intervaldate');
220 /*Configuration de la recherche avancée*/
221 $options[] = array(
222 'type' => 'search',
223 'display' => true,
224 'advanced' => $champs,
225 'default_form' => 'advanced',
226 'absolute_object' => 'dossier');
227 }
228
229 /*Ajout de sous-formulaire à notre objet*/
230 $sousformulaire=array(
231 //"donnees_techniques",
232 "instruction",
233 "consultation",
234 "lot",
235 "dossier_message",
236 "dossier_commission",
237 //"rapport_instruction",
238 "dossier_autorisation",
239 );
240
241 /*Ajout de paramètre à certains sous-formulaire*/
242 $sousformulaire_parameters = array(
243 "consultation" => array(
244 "title" => _("consultation(s)"),
245 ),
246 "dossier_message" => array(
247 "title" => _("message(s)"),
248 ),
249 "dossier_commission" => array(
250 "title" => _("commission(s)"),
251 ),
252 "rapport_instruction" => array(
253 "title" => _("rapport d'instruction"),
254 "href" => "../app/redirection_onglet.php?idx=".((isset($idx))? $idx:"")."&obj=rapport_instruction&",
255 ),
256 "lot" => array(
257 "title" => _("lot(s)"),
258 ),
259 "donnees_techniques" => array(
260 "title" => _("donnees techniques"),
261 "href" => "../app/redirection_onglet.php?idx=".((isset($idx))? $idx:"")."&obj=donnees_techniques&",
262 ),
263 "dossier_autorisation" => array(
264 "title" => _("DA"),
265 "href" => "../app/display_da_di.php?iddi=".((isset($idx))? $idx:"")."&",
266 ),
267 );
268 ?>

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26