1 |
fraynaud |
88 |
<?php |
2 |
|
|
/* |
3 |
fmichon |
1184 |
$Id$ |
4 |
fraynaud |
88 |
*/ |
5 |
|
|
// INITIALISATION DES VARIABLES |
6 |
|
|
include ("../dyn/var.inc"); |
7 |
|
|
$DEBUG = 0; |
8 |
|
|
$existe=0; |
9 |
|
|
if(isset($_GET['id'])) |
10 |
|
|
$id=$_GET['id']; |
11 |
|
|
else |
12 |
|
|
$id=""; |
13 |
|
|
if(isset($_GET['menu'])) |
14 |
|
|
$menu=$_GET['menu']; |
15 |
|
|
else |
16 |
|
|
$menu=0; |
17 |
fraynaud |
122 |
if(isset($_GET['modificatif'])) |
18 |
|
|
$modificatif=$_GET['modificatif']; |
19 |
|
|
else |
20 |
|
|
$modificatif=0; |
21 |
fraynaud |
88 |
// utils |
22 |
|
|
require_once "../obj/utils.class.php"; |
23 |
jbastide |
158 |
if($menu==1 or $menu==2) |
24 |
fraynaud |
88 |
$f = new utils(NULL, "dossier", _("dossier"), "ico_dossier.png", "dossier"); |
25 |
|
|
else{ // sans menu |
26 |
jbastide |
158 |
if($menu==0){ |
27 |
fraynaud |
88 |
$f = new utils('nohtml', "dossier", _("dossier"), "ico_dossier.png", "dossier"); |
28 |
jbastide |
158 |
$f->setFlag("htmlonly"); |
29 |
|
|
} |
30 |
fraynaud |
88 |
} |
31 |
|
|
$f->display(); |
32 |
jbastide |
156 |
if($menu==1) // html only |
33 |
fraynaud |
104 |
$f->displayStartContent(); |
34 |
jbastide |
158 |
|
35 |
fraynaud |
88 |
// db |
36 |
atreal |
313 |
if(file_exists ("../sql/".$f->db->phptype."/dossier.scr.inc.php")) |
37 |
|
|
include ("../sql/".$f->db->phptype."/dossier.scr.inc.php"); |
38 |
fraynaud |
88 |
$res=$f->db->query($sql_dossier); |
39 |
|
|
$f->isDatabaseError($res); |
40 |
fraynaud |
126 |
if(isset($f->collectivite["departement"])) |
41 |
|
|
$departement =$f->collectivite["departement"]; |
42 |
|
|
else |
43 |
|
|
$departement=""; |
44 |
|
|
|
45 |
|
|
if(isset($f->collectivite["commune"])) |
46 |
|
|
$commune = $f->collectivite["commune"]; |
47 |
|
|
else |
48 |
|
|
$commune=""; |
49 |
fraynaud |
104 |
|
50 |
fraynaud |
88 |
while ($row=& $res->fetchRow(DB_FETCHMODE_ASSOC)){ |
51 |
|
|
$existe=1; |
52 |
|
|
// dossier |
53 |
|
|
echo "<fieldset class=\"cadre ui-corner-all ui-widget-content collapsible\">\n"; |
54 |
|
|
echo "\t<legend class=\"ui-corner-all ui-widget-content ui-state-active\">"; |
55 |
|
|
echo _("Dossier ")."</legend>"; |
56 |
fraynaud |
152 |
echo "<table width='95%'>"; |
57 |
|
|
echo "<tr><td colspan='5'><b>"._("tableau_bord")." "._("dossier")." ".$row['nature']."</b></td></tr>"; |
58 |
fraynaud |
197 |
echo "<tr><td colspan='5'><i> No </i> ".$departement." ".$commune." ".$row['dossier']." <i>"._("date_depot")." :</i>".$row['date_depot']."</td></tr>"; |
59 |
|
|
echo "<tr><td colspan='5'><i>"._("demandeur_nom")." :</i> ".$row['demandeur_civilite']." ". $row['demandeur_nom']."<br>"; |
60 |
|
|
echo "<i>"._("demandeur_adresse")." : </i>".$row['demandeur_adresse']." ". |
61 |
|
|
$row['demandeur_cp']." - ".$row['demandeur_ville']."</td></tr>"; |
62 |
|
|
echo "<tr><td colspan='5'><i>"._("demandeur_societe")." : </i>".$row['demandeur_societe']."</td></tr>"; |
63 |
fraynaud |
152 |
echo "<tr><td colspan='5'><a class='liendossier' href='".$lien_sig1.$row['rivoli'].$row['terrain_numero']. |
64 |
fraynaud |
197 |
"' target=_blank><span class=\"om-icon om-icon-16 om-icon-fix sig-16\" title=\""._("Sig")."\">"._("Sig")."</span><i> adresse du terrain : </i>". |
65 |
fraynaud |
104 |
$row['terrain_numero']." ". |
66 |
|
|
$row['terrain_adresse']." ".$row['terrain_cp']." - ". |
67 |
|
|
$row['terrain_ville']."</a><br>"; |
68 |
fraynaud |
197 |
echo "<a class='liendossier' href='".$lien_sig.$row['parcelle']."' target=_blank><span class=\"om-icon om-icon-16 om-icon-fix sig-16\" title=\""._("Sig")."\">"._("Sig")."</span><i> parcelle : </i>". |
69 |
fraynaud |
104 |
$row['parcelle']."</a><br>"; |
70 |
fraynaud |
197 |
echo "<a class='liendossier' href='".$lien_sig2.$row['dossier']."' target=_blank><span class=\"om-icon om-icon-16 om-icon-fix sig-16\" title=\""._("Sig")."\">"._("Sig")."</span><i> dossier : </i>". |
71 |
fraynaud |
152 |
$row['dossier']."</a></td></tr>"; |
72 |
fraynaud |
197 |
echo "<tr><td colspan='5'><b><i>Amenagement : </i></b><a class='liendossier' href='dossier.php?id=".$row['amenagement']."&menu=1'>". |
73 |
fraynaud |
152 |
$row['amenagement']."</a> - ".$row['parcelle_lot_lotissement']."</td></tr>"; |
74 |
fraynaud |
104 |
// dossier caracteristique |
75 |
fraynaud |
197 |
echo "<tr><td colspan='5'><b><i>"._("servitude")." : </i></b>".$row['servitude']."<br>"; |
76 |
fraynaud |
152 |
echo ""; |
77 |
fraynaud |
197 |
echo "<tr ><td colspan='5'><b><i>"._("caracteristique")." : </i></b></td><tr>"; |
78 |
|
|
echo "<tr><td><i>"._("shob")." : </i>".$row['shob']. |
79 |
|
|
" m2 </td><td><i>"._("shon")." : </i>".$row['shon']." m2 "; |
80 |
|
|
echo "</td><td><i>"._("hauteur")." :</i>".$row['hauteur']." m </td><td><i>"._("logement_nombre")." :</i>". |
81 |
|
|
$row['logement_nombre']."</td><td><i>"._("batiment_nombre")." : </i>".$row['batiment_nombre']."</td><tr>"; |
82 |
atreal |
314 |
echo "<tr><td colspan='5'><i>"._("travaux")." : </i>".$row['travaux'].' - '.$row['travaux_complement']."</td><tr>"; |
83 |
fraynaud |
197 |
echo "<tr ><td colspan='5'><b><i>"._("Etat")." "._("instruction")." : </i></b></td><tr>"; |
84 |
|
|
echo "<tr><td><i>"._("date_depot")." : </i>".$row['date_depot']." "; |
85 |
|
|
echo "</td><td><i>"._("date_notification_delai")." : </i>". |
86 |
fraynaud |
88 |
$row['date_notification_delai']." - "; |
87 |
fraynaud |
197 |
echo "</td><td><i>"._("date_limite").": </i>".$row['date_limite']. |
88 |
fraynaud |
88 |
"</td><td></td><td></td></tr>"; |
89 |
fraynaud |
197 |
echo "<tr><td><i>"._("date_validite")." : </i>".$row['date_validite']." "; |
90 |
|
|
echo "</td><td><i>"._("date_chantier")." : </i>". |
91 |
|
|
$row['date_chantier'].""; |
92 |
|
|
echo "</td><td><i>"._("date_achevement").": </i>".$row['date_achevement']. |
93 |
|
|
"</td><td><i>"._("date_conformite").": </i>".$row['date_conformite']."</td><td></td></tr>"; |
94 |
fraynaud |
88 |
echo "\t\t\t</table>\n"; |
95 |
|
|
echo "</fieldset>"; |
96 |
|
|
// instruction |
97 |
|
|
$res1=$f->db->query($sql_instruction); |
98 |
|
|
$f->isDatabaseError($res1); |
99 |
|
|
echo "<fieldset class=\"cadre ui-corner-all ui-widget-content startClosed\">\n"; |
100 |
|
|
echo "\t<legend class=\"ui-corner-all ui-widget-content ui-state-active\">"; |
101 |
|
|
echo _("Instruction ")."</legend>"; |
102 |
|
|
echo "<table width='95%'>"; |
103 |
vpihour |
1127 |
echo "<tr><td></td><td><i>"._("evenement")."</i></td><td><i>"._("lettretype")."</i></td><td><i>"._("date_evenement")."</i></td><tr>"; |
104 |
fraynaud |
88 |
while ($row1=& $res1->fetchRow(DB_FETCHMODE_ASSOC)){ |
105 |
jbastide |
162 |
echo "<tr><td><a class='liendossier' href='../app/pdflettretype_instruction.php?idx=". |
106 |
|
|
$row1['instruction']."' ><span class=\"om-icon om-icon-16 om-icon-fix pdf-16\" title=\""._("Edition")."\">"._("Edition")."</span></a></td>"; |
107 |
fraynaud |
88 |
echo "<td>".$row1['evenement']."</td><td>". |
108 |
vpihour |
1127 |
$row1['lettretype']."</td><td>".$row1['date_evenement']."</td><tr>"; |
109 |
fraynaud |
88 |
} |
110 |
|
|
echo "</table>"; |
111 |
|
|
echo "</fieldset>"; |
112 |
|
|
|
113 |
|
|
// consultation |
114 |
|
|
echo "<fieldset class=\"cadre ui-corner-all ui-widget-content startClosed\">\n"; |
115 |
|
|
echo "\t<legend class=\"ui-corner-all ui-widget-content ui-state-active\">"; |
116 |
|
|
echo _("Consultation ")."</legend>"; |
117 |
|
|
$res2=$f->db->query($sql_consultation); |
118 |
|
|
$f->isDatabaseError($res2); |
119 |
|
|
echo "<table width='95%'>"; |
120 |
vpihour |
510 |
echo "<tr><td></td><td><i>"._("date_envoi")."</i></td><td><i>"._("avis_consultation"). |
121 |
fraynaud |
197 |
"</i></td><td><i>"._("date_envoi")."</i></td><td><i>"._("date_limite")."</i></td><tr>"; |
122 |
fraynaud |
88 |
while ($row2=& $res2->fetchRow(DB_FETCHMODE_ASSOC)){ |
123 |
fmichon |
1341 |
echo "<tr><td><a class='liendossier' href='../app/pdf_consultation.php?obj=consultation&idx=". |
124 |
jbastide |
162 |
$row2['consultation']."' ><span class=\"om-icon om-icon-16 om-icon-fix pdf-16\" title=\""._("Edition")."\">"._("Edition")."</span></a></td>"; |
125 |
vpihour |
510 |
echo "<td>".$row2['envoi']."</td><td>".$row2['avis_consultation']."</td><td>". |
126 |
fraynaud |
88 |
$row2['retour']."</td><td>".$row2['limite']."</td><tr>"; |
127 |
|
|
} |
128 |
|
|
echo "</table>"; |
129 |
|
|
echo "</fieldset>"; |
130 |
|
|
|
131 |
|
|
// terrain |
132 |
|
|
echo "<fieldset class=\"cadre ui-corner-all ui-widget-content startClosed\">\n"; |
133 |
|
|
echo "\t<legend class=\"ui-corner-all ui-widget-content ui-state-active\">"; |
134 |
|
|
echo _("Terrain ")."</legend>"; |
135 |
|
|
$res3=$f->db->query($sql_terrain); |
136 |
|
|
$f->isDatabaseError($res3); |
137 |
|
|
echo "<table width='95%'>"; |
138 |
fraynaud |
197 |
echo "<tr><td><i>"._("parcelle")."</i></td><td><i>"._("proprietaire"). |
139 |
|
|
"</i></td><td><i>"._("surface")."</i></td><tr>"; |
140 |
fraynaud |
88 |
while ($row3=& $res3->fetchRow(DB_FETCHMODE_ASSOC)){ |
141 |
jbastide |
162 |
echo "<tr><td><a class='liendossier' href='".$lien_sig.$row3['parcelle']. |
142 |
|
|
"' target=_blank><span class=\"om-icon om-icon-16 om-icon-fix sig-16\" title=\""._("Sig")."\">"._("Sig")."</span> ".$row3['parcelle']."</td><td>". |
143 |
fraynaud |
88 |
$row3['proprietaire']."</td><td>".$row3['surface']." m2</td><tr>"; |
144 |
|
|
} |
145 |
|
|
echo "</table>"; |
146 |
|
|
echo "</fieldset>"; |
147 |
|
|
|
148 |
|
|
// destination_shon |
149 |
|
|
echo "<fieldset class=\"cadre ui-corner-all ui-widget-content startClosed\">\n"; |
150 |
|
|
echo "\t<legend class=\"ui-corner-all ui-widget-content ui-state-active\">"; |
151 |
|
|
echo _("Destination")."</legend>"; |
152 |
|
|
$res4=$f->db->query($sql_destination_shon); |
153 |
|
|
$f->isDatabaseError($res4); |
154 |
|
|
echo "<table width='95%'>"; |
155 |
fraynaud |
197 |
echo "<tr><td><i>No</i></td><td><i>"._("destination")."</i></td><td>". |
156 |
|
|
_("shon")."</td>"; |
157 |
|
|
echo "<td><i>"._("shon_anterieure")."</i></td>"; |
158 |
|
|
echo "<td><i>"._("shon_demolie")."</i></td>"; |
159 |
|
|
echo "<td><i>"._("shon_anterieure_supprimee")."</i></td>"; |
160 |
|
|
echo "<td><i>"._("shon_nouvelle_transformee")."</i></td>"; |
161 |
|
|
echo "<td><i>"._("shon_nouvelle")."</i></td>"; |
162 |
|
|
echo "<td><i>"._("shon_shob_transformee")."</i></td>"; |
163 |
|
|
echo "</tr>"; |
164 |
fraynaud |
88 |
while ($row4=& $res4->fetchRow(DB_FETCHMODE_ASSOC)){ |
165 |
|
|
echo "<tr><td>".$row4['no']."</td><td>". |
166 |
fraynaud |
196 |
$row4['libelle']."</td><td><b>".$row4['shon']." m2</b></td>"; |
167 |
|
|
echo "<td>".$row4['shon_anterieure']." m2</td>"; |
168 |
fraynaud |
197 |
echo "<td>".$row4['shon_demolie']." m2</td>"; |
169 |
|
|
echo "<td>".$row4['shon_anterieure_supprimee']." m2</td>"; |
170 |
|
|
echo "<td>".$row4['shon_nouvelle_transformee']." m2</td>"; |
171 |
|
|
echo "<td>".$row4['shon_nouvelle']." m2</td>"; |
172 |
|
|
echo "<td>".$row4['shon_shob_transformee']." m2</td>"; |
173 |
fraynaud |
196 |
echo "<tr>"; |
174 |
fraynaud |
88 |
} |
175 |
|
|
echo "</table>"; |
176 |
|
|
echo "</fieldset>"; |
177 |
fraynaud |
196 |
|
178 |
|
|
|
179 |
fraynaud |
88 |
// modificatif |
180 |
|
|
echo "<fieldset class=\"cadre ui-corner-all ui-widget-content startClosed\">\n"; |
181 |
|
|
echo "\t<legend class=\"ui-corner-all ui-widget-content ui-state-active\">"; |
182 |
fraynaud |
152 |
echo _("Modificatif")." "._("transfert")."</legend>"; |
183 |
fraynaud |
88 |
$res5=$f->db->query($sql_modificatif); |
184 |
|
|
$f->isDatabaseError($res5); |
185 |
|
|
echo "<table width='95%'>"; |
186 |
fraynaud |
197 |
echo "<tr><td><i>"._("date_demande")."</i></td><td><i>"._("demandeur_nom"). |
187 |
|
|
"</i></td><td><i>"._("Etat")."</i></td><tr>"; |
188 |
fraynaud |
88 |
while ($row5=& $res5->fetchRow(DB_FETCHMODE_ASSOC)){ |
189 |
fraynaud |
104 |
echo "<tr><td>"; |
190 |
fraynaud |
196 |
if($modificatif==0){ |
191 |
|
|
echo "<a class='liendossier' href='dossier.php?id=". |
192 |
|
|
$row5['dossier']."&menu=".$menu."' ><img src='img/ico_exemplaire.png'> ".$row5['demande']."</a></td>"; |
193 |
fraynaud |
197 |
echo "<td>".$row5['demandeur_nom']."</td><td>".$row5['etat']."</td><tr>"; |
194 |
fraynaud |
196 |
}else{ |
195 |
|
|
echo "".$row5['demande']."</td>"; |
196 |
|
|
echo "<td>".$row5['demandeur_nom']."</td><td>".$row5['etat']."</td><tr>"; |
197 |
|
|
} |
198 |
fraynaud |
88 |
} |
199 |
|
|
echo "</table>"; |
200 |
|
|
echo "</fieldset>"; |
201 |
fraynaud |
197 |
|
202 |
|
|
// statistique |
203 |
|
|
echo "<fieldset class=\"cadre ui-corner-all ui-widget-content startClosed\">\n"; |
204 |
|
|
echo "\t<legend class=\"ui-corner-all ui-widget-content ui-state-active\">"; |
205 |
|
|
echo _("Statistique")." "."</legend>"; |
206 |
|
|
$res6=$f->db->query($sql_statistique); |
207 |
|
|
$f->isDatabaseError($res6); |
208 |
|
|
echo "<table width='95%'>"; |
209 |
|
|
echo "<tr><td><i>"._("statistique")."</i></td><td><i>". |
210 |
|
|
_("parametre")."</i></td><td><i>"._("valeur")."</i></td><tr>"; |
211 |
|
|
while ($row6=& $res6->fetchRow(DB_FETCHMODE_ASSOC)){ |
212 |
|
|
echo "<tr><td>"; |
213 |
|
|
echo $row6['statistique']."</td><td>".$row6['parametre']."</td>"; |
214 |
|
|
echo "<td>".$row6['valeur']."</td>"; |
215 |
|
|
echo "<tr>"; |
216 |
|
|
} |
217 |
|
|
echo "</table>"; |
218 |
|
|
echo "</fieldset>"; |
219 |
fraynaud |
88 |
} // while dossier |
220 |
fraynaud |
104 |
if($menu==0){ |
221 |
fraynaud |
122 |
if($modificatif==0){ |
222 |
fraynaud |
104 |
echo "<center>"; |
223 |
|
|
$f->displayLinkJsCloseWindow(); // **** |
224 |
|
|
echo "</center>"; |
225 |
|
|
$f->displayEndContent(); |
226 |
fraynaud |
122 |
} |
227 |
fraynaud |
104 |
} |
228 |
jbastide |
158 |
|
229 |
fraynaud |
88 |
if($existe==0){ |
230 |
fraynaud |
104 |
$msg=$idx._(" inexistant en base openFoncier"); |
231 |
fraynaud |
88 |
$f->displayMessage($class, $message); |
232 |
|
|
} |
233 |
|
|
?> |