40 |
"om_fichier_instruction" => array( |
"om_fichier_instruction" => array( |
41 |
"dossier" => "getDossier", |
"dossier" => "getDossier", |
42 |
"dossier_version" => "getDossierVersion", |
"dossier_version" => "getDossierVersion", |
43 |
"numDemandeAutor" => "getDossierAutorisation", |
"numDemandeAutor" => "getNumDemandeAutor", |
44 |
"anneemoisDemandeAutori" => "getDateDemandeInitiale", |
"anneemoisDemandeAutor" => "getAnneemoisDemandeAutor", |
45 |
"typeInstructionAutorisation" => "getDossierInstructionType", |
"typeInstruction" => "getTypeInstruction", |
46 |
"statutAutorisation" => "getStatut", |
"statutAutorisation" => "getStatutAutorisation", |
47 |
"typeAutorisation" => "getDossierAutorisationType", |
"typeAutorisation" => "getTypeAutorisation", |
48 |
"dateEvenementDocument" => "getDateEvenement", |
"dateEvenementDocument" => "getDateEvenementDocument", |
49 |
"groupeInstruction" => 'getGroupeInstruction', |
"groupeInstruction" => 'getGroupeInstruction', |
50 |
"title" => 'getEvenementLibelle', |
"title" => 'getTitle', |
51 |
), |
), |
52 |
"document_arrete" => array( |
"document_arrete" => array( |
53 |
"numArrete" => "getNumArrete", |
"numArrete" => "getNumArrete", |
54 |
"specialiteArrete" => "getSpecialiteArrete", |
"ReglementaireArrete" => "getReglementaireArrete", |
55 |
"decisionArrete" => "getDecisionArrete", |
"NotificationArrete" => "getNotificationArrete", |
56 |
"chketatReglementaire" => "getChketatReglementaire", |
"dateNotificationArrete" => "getDateNotificationArrete", |
57 |
"chkNotification" => "getChkNotification", |
"controleLegalite" => "getControleLegalite", |
58 |
"dateNotification" => "getDateNotification", |
"dateSignature" => "getDateSignature", |
|
"chkCreationdroit" => "getChkCreationdroit", |
|
|
"chkPublication" => "getChkPublication", |
|
|
"datePublication" => "getDatePublication", |
|
|
"chkControleLegalite" => "getChkControleLegalite", |
|
|
"dateSignatureArrete" => "getDateSignatureArrete", |
|
59 |
"nomSignataire" => "getNomSignataire", |
"nomSignataire" => "getNomSignataire", |
60 |
"qualiteSignataire" => "getQualiteSignataire", |
"qualiteSignataire" => "getQualiteSignataire", |
|
"chkDelegation" => "getChkDelegation", |
|
61 |
"ap_numRue" => "getAp_numRue", |
"ap_numRue" => "getAp_numRue", |
62 |
"ap_nomDeLaVoie" => "getAp_nomDeLaVoie", |
"ap_nomDeLaVoie" => "getAp_nomDeLaVoie", |
63 |
"ap_codePostal" => "getAp_codePostal", |
"ap_codePostal" => "getAp_codePostal", |
64 |
"ap_ville" => "getAp_ville", |
"ap_ville" => "getAp_ville", |
65 |
|
"activite" => "getActivite", |
66 |
|
"dateControleLegalite" => "getDateControleLegalite", |
67 |
|
"permanentArrete" => "getPermanentArrete", |
68 |
), |
), |
69 |
); |
); |
70 |
|
|
139 |
)){ |
)){ |
140 |
|
|
141 |
//On récuppère le statut du dossier d'instruction |
//On récuppère le statut du dossier d'instruction |
142 |
$statut = $this->getStatutDossier($idxformulaire); |
$statut = $this->getStatutAutorisationDossier($idxformulaire); |
143 |
if ( $this->f->isUserInstructeur() && $statut == "cloture" ){ |
if ( $this->f->isUserInstructeur() && $statut == "cloture" ){ |
144 |
|
|
145 |
//On cache le lien de modification |
//On cache le lien de modification |
168 |
$retourformulaire = $this->getParameter("retourformulaire"); |
$retourformulaire = $this->getParameter("retourformulaire"); |
169 |
// Si l'utilisateur est un instructeur et que le dossier est cloturé |
// Si l'utilisateur est un instructeur et que le dossier est cloturé |
170 |
if ( $this->f->isUserInstructeur() && |
if ( $this->f->isUserInstructeur() && |
171 |
$this->getStatutDossier($this->getParameter("idxformulaire")) == "cloture" && |
$this->getStatutAutorisationDossier($this->getParameter("idxformulaire")) == "cloture" && |
172 |
( |
( |
173 |
$retourformulaire == 'dossier' || |
$retourformulaire == 'dossier' || |
174 |
$retourformulaire == 'dossier_instruction' || |
$retourformulaire == 'dossier_instruction' || |
246 |
/** |
/** |
247 |
* Cette méthode permet de récupérer le dossier d'autorisation d'un dossier |
* Cette méthode permet de récupérer le dossier d'autorisation d'un dossier |
248 |
*/ |
*/ |
249 |
function getDossierAutorisationFromDossier($id) { |
function getNumDemandeAutorFromDossier($id) { |
250 |
// |
// |
251 |
if (!isset($id)) { |
if (!isset($id)) { |
252 |
return NULL; |
return NULL; |
256 |
$sql .= " where dossier='".$id."'"; |
$sql .= " where dossier='".$id."'"; |
257 |
// |
// |
258 |
$dossier_autorisation = $this->db->getOne($sql); |
$dossier_autorisation = $this->db->getOne($sql); |
259 |
$this->addToLog("getDossierAutorisationFromDossier(): db->getone(\"".$sql."\")", VERBOSE_MODE); |
$this->addToLog("getNumDemandeAutorFromDossier(): db->getone(\"".$sql."\")", VERBOSE_MODE); |
260 |
database::isError($dossier_autorisation); |
database::isError($dossier_autorisation); |
261 |
// |
// |
262 |
return $dossier_autorisation; |
return $dossier_autorisation; |
1061 |
|
|
1062 |
// Mise à jour des données du dossier d'autorisation |
// Mise à jour des données du dossier d'autorisation |
1063 |
require_once "../obj/dossier_autorisation.class.php"; |
require_once "../obj/dossier_autorisation.class.php"; |
1064 |
$da = new dossier_autorisation($this->getDossierAutorisationFromDossier($this->valF['dossier']), $this->db, DEBUG); |
$da = new dossier_autorisation($this->getNumDemandeAutorFromDossier($this->valF['dossier']), $this->db, DEBUG); |
1065 |
$da->majDossierAutorisation(); |
$da->majDossierAutorisation(); |
1066 |
} |
} |
1067 |
function triggermodifier($id,&$db,$val,$DEBUG) { |
function triggermodifier($id,&$db,$val,$DEBUG) { |
1275 |
|
|
1276 |
// Mise à jour des données du dossier d'autorisation |
// Mise à jour des données du dossier d'autorisation |
1277 |
require_once "../obj/dossier_autorisation.class.php"; |
require_once "../obj/dossier_autorisation.class.php"; |
1278 |
$da = new dossier_autorisation($this->getDossierAutorisationFromDossier($this->valF['dossier']), $this->db, DEBUG); |
$da = new dossier_autorisation($this->getNumDemandeAutorFromDossier($this->valF['dossier']), $this->db, DEBUG); |
1279 |
$da->majDossierAutorisation(); |
$da->majDossierAutorisation(); |
1280 |
} |
} |
1281 |
|
|
1318 |
return $this->valF['numero_arrete']; |
return $this->valF['numero_arrete']; |
1319 |
} |
} |
1320 |
/** |
/** |
|
* @return string ads |
|
|
*/ |
|
|
function getSpecialiteArrete() { |
|
|
return "ADS"; |
|
|
} |
|
|
/** |
|
|
* @return string decision |
|
|
*/ |
|
|
function getDecisionArrete() { |
|
|
if (empty($this->metadonneesArrete)) { |
|
|
$this->getArreteMetadata(); |
|
|
} |
|
|
return $this->metadonneesArrete["decisionarrete"]; |
|
|
} |
|
|
/** |
|
1321 |
* @return chaîne vide |
* @return chaîne vide |
1322 |
*/ |
*/ |
1323 |
function getChketatReglementaire() { |
function getReglementaireArrete() { |
1324 |
return ""; |
return ""; |
1325 |
} |
} |
1326 |
/** |
/** |
1327 |
* @return boolean de notification au pétitionnaire |
* @return boolean de notification au pétitionnaire |
1328 |
*/ |
*/ |
1329 |
function getChkNotification() { |
function getNotificationArrete() { |
1330 |
if( isset($this->valF["date_retour_rar"]) ) { |
if( isset($this->valF["date_retour_rar"]) ) { |
1331 |
return true; |
return true; |
1332 |
} else { |
} else { |
1336 |
/** |
/** |
1337 |
* @return date de notification au pétitionnaire |
* @return date de notification au pétitionnaire |
1338 |
*/ |
*/ |
1339 |
function getDateNotification() { |
function getDateNotificationArrete() { |
1340 |
return date("d/m/Y", strtotime($this->valF["date_retour_rar"])); |
return date("d/m/Y", strtotime($this->valF["date_retour_rar"])); |
1341 |
} |
} |
1342 |
/** |
/** |
|
* @return chaîne vide |
|
|
*/ |
|
|
function getChkCreationdroit() { |
|
|
return ""; |
|
|
} |
|
|
/** |
|
|
* @return chaîne vide |
|
|
*/ |
|
|
function getChkPublication() { |
|
|
return ""; |
|
|
} |
|
|
/** |
|
|
* @return chaîne vide |
|
|
*/ |
|
|
function getDatePublication() { |
|
|
return ""; |
|
|
} |
|
|
/** |
|
1343 |
* @return boolean check si le document est passé au contrôle de légalité |
* @return boolean check si le document est passé au contrôle de légalité |
1344 |
*/ |
*/ |
1345 |
function getChkControleLegalite() { |
function getControleLegalite() { |
1346 |
if( isset($this->valF["date_retour_controle_legalite"]) ) { |
if( isset($this->valF["date_retour_controle_legalite"]) ) { |
1347 |
return true; |
return true; |
1348 |
} else { |
} else { |
1352 |
/** |
/** |
1353 |
* @return date de signature de l'arrêté |
* @return date de signature de l'arrêté |
1354 |
*/ |
*/ |
1355 |
function getDateSignatureArrete() { |
function getDateSignature() { |
1356 |
return date("d/m/Y", strtotime($this->valF['date_retour_signature'])); |
return date("d/m/Y", strtotime($this->valF['date_retour_signature'])); |
1357 |
} |
} |
1358 |
/** |
/** |
1374 |
return $this->metadonneesArrete["qualitesignataire"]; |
return $this->metadonneesArrete["qualitesignataire"]; |
1375 |
} |
} |
1376 |
/** |
/** |
|
* @return string chaîne vide |
|
|
*/ |
|
|
function getChkDelegation() { |
|
|
return ""; |
|
|
} |
|
|
/** |
|
1377 |
* @return string numéro du terrain |
* @return string numéro du terrain |
1378 |
*/ |
*/ |
1379 |
function getAp_numRue() { |
function getAp_numRue() { |
1409 |
} |
} |
1410 |
return $this->metadonneesArrete["ap_ville"]; |
return $this->metadonneesArrete["ap_ville"]; |
1411 |
} |
} |
1412 |
|
/** |
1413 |
|
* @return string activité |
1414 |
|
*/ |
1415 |
|
function getActivite() { |
1416 |
|
return "Droit du sol"; |
1417 |
|
} |
1418 |
|
/** |
1419 |
|
* @return string vide |
1420 |
|
*/ |
1421 |
|
function getDateControleLegalite() { |
1422 |
|
return ""; |
1423 |
|
} |
1424 |
|
/** |
1425 |
|
* @return string vide |
1426 |
|
*/ |
1427 |
|
function getPermanentArrete() { |
1428 |
|
return ""; |
1429 |
|
} |
1430 |
|
|
1431 |
// Fin des méthodes de récupération des métadonnées |
// Fin des méthodes de récupération des métadonnées |
1432 |
// }}} |
// }}} |
1547 |
|
|
1548 |
// Mise à jour des données du dossier d'autorisation |
// Mise à jour des données du dossier d'autorisation |
1549 |
require_once "../obj/dossier_autorisation.class.php"; |
require_once "../obj/dossier_autorisation.class.php"; |
1550 |
$da = new dossier_autorisation($this->getDossierAutorisationFromDossier($val["dossier"]), $this->db, DEBUG); |
$da = new dossier_autorisation($this->getNumDemandeAutorFromDossier($val["dossier"]), $this->db, DEBUG); |
1551 |
$da->majDossierAutorisation(); |
$da->majDossierAutorisation(); |
1552 |
} |
} |
1553 |
|
|
1922 |
* Récupération du numéro de dossier d'autorisation à ajouter aux métadonnées |
* Récupération du numéro de dossier d'autorisation à ajouter aux métadonnées |
1923 |
* @return string numéro de dossier d'autorisation |
* @return string numéro de dossier d'autorisation |
1924 |
*/ |
*/ |
1925 |
protected function getDossierAutorisation() { |
protected function getNumDemandeAutor() { |
1926 |
if(empty($this->specificMetadata)) { |
if(empty($this->specificMetadata)) { |
1927 |
$this->getSpecificMetadata(); |
$this->getSpecificMetadata(); |
1928 |
} |
} |
1932 |
* Récupération de la date de demande initiale du dossier à ajouter aux métadonnées |
* Récupération de la date de demande initiale du dossier à ajouter aux métadonnées |
1933 |
* @return date de la demande initiale |
* @return date de la demande initiale |
1934 |
*/ |
*/ |
1935 |
protected function getDateDemandeInitiale() { |
protected function getAnneemoisDemandeAutor() { |
1936 |
if(empty($this->specificMetadata)) { |
if(empty($this->specificMetadata)) { |
1937 |
$this->getSpecificMetadata(); |
$this->getSpecificMetadata(); |
1938 |
} |
} |
1942 |
* Récupération du type de dossier d'instruction à ajouter aux métadonnées |
* Récupération du type de dossier d'instruction à ajouter aux métadonnées |
1943 |
* @return string type du dossier d'instruction |
* @return string type du dossier d'instruction |
1944 |
*/ |
*/ |
1945 |
protected function getDossierInstructionType() { |
protected function getTypeInstruction() { |
1946 |
if(empty($this->specificMetadata)) { |
if(empty($this->specificMetadata)) { |
1947 |
$this->getSpecificMetadata(); |
$this->getSpecificMetadata(); |
1948 |
} |
} |
1952 |
* Récupération du statut du dossier d'autorisation à ajouter aux métadonnées |
* Récupération du statut du dossier d'autorisation à ajouter aux métadonnées |
1953 |
* @return string avis |
* @return string avis |
1954 |
*/ |
*/ |
1955 |
protected function getStatut() { |
protected function getStatutAutorisation() { |
1956 |
if(empty($this->specificMetadata)) { |
if(empty($this->specificMetadata)) { |
1957 |
$this->getSpecificMetadata(); |
$this->getSpecificMetadata(); |
1958 |
} |
} |
1962 |
* Récupération du type de dossier d'autorisation à ajouter aux métadonnées |
* Récupération du type de dossier d'autorisation à ajouter aux métadonnées |
1963 |
* @return string type du dossier d'autorisation |
* @return string type du dossier d'autorisation |
1964 |
*/ |
*/ |
1965 |
protected function getDossierAutorisationType() { |
protected function getTypeAutorisation() { |
1966 |
if(empty($this->specificMetadata)) { |
if(empty($this->specificMetadata)) { |
1967 |
$this->getSpecificMetadata(); |
$this->getSpecificMetadata(); |
1968 |
} |
} |
1972 |
* Récupération de la date d'ajout de document à ajouter aux métadonnées |
* Récupération de la date d'ajout de document à ajouter aux métadonnées |
1973 |
* @return date de l'évènement |
* @return date de l'évènement |
1974 |
*/ |
*/ |
1975 |
protected function getDateEvenement() { |
protected function getDateEvenementDocument() { |
1976 |
return date("d/m/Y"); |
return date("d/m/Y"); |
1977 |
} |
} |
1978 |
/** |
/** |
1989 |
* Récupération du libellé du type du document à ajouter aux métadonnées |
* Récupération du libellé du type du document à ajouter aux métadonnées |
1990 |
* @return string Groupe d'instruction |
* @return string Groupe d'instruction |
1991 |
*/ |
*/ |
1992 |
protected function getEvenementLibelle() { |
protected function getTitle() { |
1993 |
|
|
1994 |
// Récupère le champ événement |
// Récupère le champ événement |
1995 |
if (isset($this->valF["evenement"]) AND $this->valF["evenement"] != "") { |
if (isset($this->valF["evenement"]) AND $this->valF["evenement"] != "") { |
2002 |
$sql = "SELECT libelle FROM ".DB_PREFIXE."evenement |
$sql = "SELECT libelle FROM ".DB_PREFIXE."evenement |
2003 |
WHERE evenement=".$evenement; |
WHERE evenement=".$evenement; |
2004 |
$evenement_libelle = $this->db->getOne($sql); |
$evenement_libelle = $this->db->getOne($sql); |
2005 |
$this->addToLog("getEvenementLibelle(): db->getOne(\"".$sql."\");", VERBOSE_MODE); |
$this->addToLog("getTitle(): db->getOne(\"".$sql."\");", VERBOSE_MODE); |
2006 |
if (database::isError($evenement_libelle)) { |
if (database::isError($evenement_libelle)) { |
2007 |
die(); |
die(); |
2008 |
} |
} |
2067 |
* @param string $idx Identifiant du dossier d'instruction |
* @param string $idx Identifiant du dossier d'instruction |
2068 |
* @return string Le statut du dossier d'instruction |
* @return string Le statut du dossier d'instruction |
2069 |
*/ |
*/ |
2070 |
function getStatutDossier($idx){ |
function getStatutAutorisationDossier($idx){ |
2071 |
|
|
2072 |
$statut = ''; |
$statut = ''; |
2073 |
|
|
2084 |
dossier.etat = etat.etat |
dossier.etat = etat.etat |
2085 |
WHERE dossier ='".$idx."'"; |
WHERE dossier ='".$idx."'"; |
2086 |
$statut = $this->db->getOne($sql); |
$statut = $this->db->getOne($sql); |
2087 |
$this->f->addToLog("getStatutDossier() : db->getOne(\"".$sql."\")", VERBOSE_MODE); |
$this->f->addToLog("getStatutAutorisationDossier() : db->getOne(\"".$sql."\")", VERBOSE_MODE); |
2088 |
if ( database::isError($statut)){ |
if ( database::isError($statut)){ |
2089 |
die(); |
die(); |
2090 |
} |
} |