diff --git a/Controleur/ControleurAjaximporterlisteassure.php b/Controleur/ControleurAjaximporterlisteassure.php index 6cee698..f9dc37f 100644 --- a/Controleur/ControleurAjaximporterlisteassure.php +++ b/Controleur/ControleurAjaximporterlisteassure.php @@ -87,133 +87,122 @@ class ControleurAjaximporterlisteassure extends Controleurrequete public function importermodele() { - $idAvenant = $this->requete->getParametreFormulaire("idAvenant"); - $cheminFichier = $this->requete->getParametreFormulaire("cheminFichier"); + $idAvenant = $this->requete->getParametreFormulaire("idAvenant"); + $cheminFichier = $this->requete->getParametreFormulaire("cheminFichier"); $_SESSION['idAvenant_C'] = $idAvenant; - $this->beneficiaire->initIinsererLigneModeleAssure(); - $dataXLS = array(); - $fichier = "Temp/import/".$cheminFichier; - if (!file_exists($fichier)) - { - $this->genererVueAjax(array('message_erreur_excel' => "Fichier introubable sur le serveur !", 'succes_impot_execl' => "0")); + // 1. Vérification du fichier + if (!file_exists($fichier)) { + $this->genererVueAjax(array( + 'message_erreur_excel' => "Erreur : Fichier introuvable sur le serveur !", + 'succes_impot_execl' => "0" + )); exit(); } - /* - $docXLS = new PHPExcel_Reader_Excel2007(); - - $Excel = $docXLS->load($fichier); - - $Excel->setActiveSheetIndex(0); - - $feuille=$Excel->getActiveSheet(); - */ - - $docXLS = new \PhpOffice\PhpSpreadsheet\Reader\Xlsx(); - $Excel = $docXLS->load($fichier); - $feuille = $Excel->getSheet($Excel->getFirstSheetIndex()); - - - $derniereLigne = $feuille->getHighestRow(); - $derniereColonne = $feuille->getHighestColumn(); - - $tableauExcel = $feuille->toArray(null, true, true, true); - - for ($i = 2; $i <= $derniereLigne; $i++) - { - $categorie = trim($tableauExcel[$i]['A']); - $numeroAdherent = trim($tableauExcel[$i]['B']); - - $noFamille = trim($tableauExcel[$i]['C']); - if ($noFamille<=" ") + try { + $docXLS = new \PhpOffice\PhpSpreadsheet\Reader\Xlsx(); + $Excel = $docXLS->load($fichier); + $feuille = $Excel->getSheet($Excel->getFirstSheetIndex()); + + $derniereLigne = $feuille->getHighestRow(); + $tableauExcel = $feuille->toArray(null, true, true, true); + + // 2. Boucle de validation et insertion + for ($i = 2; $i <= $derniereLigne; $i++) { - $noFamille = "0"; + $categorie = trim($tableauExcel[$i]['A']); + $numeroAdherent = trim($tableauExcel[$i]['B']); + + $noFamille = trim($tableauExcel[$i]['C']); + if ($noFamille<=" ") + { + $noFamille = "0"; + } + + $nom = trim($tableauExcel[$i]['D']); + $prenoms = trim($tableauExcel[$i]['E']); + + $codeLienParente = trim($tableauExcel[$i]['F']); + + $codeNaturePiece = trim($tableauExcel[$i]['G']); + $numeroPiece = trim($tableauExcel[$i]['H']); + $sexe = trim($tableauExcel[$i]['I']); + $codeGroupeSanguin = trim($tableauExcel[$i]['J']); + $dateNaissance = trim($tableauExcel[$i]['K']); + $telephonePortable = trim($tableauExcel[$i]['L']); + $email = trim($tableauExcel[$i]['M']); + + $nomComplet = $nom . " " . $prenoms; + + + // Validation Catégorie + if ( (trim($tableauExcel[$i]['A']) <= " ") && ($codeLienParente == "A")) { + $this->renvoyerErreurImport("Ligne $i : $nomComplet => Pas de catégorie !"); + } + + // Validation Lien de parenté + if (!in_array($codeLienParente, array("A", "C", "E", "O"))) { + $this->renvoyerErreurImport("Ligne $i : $nomComplet => Lien de parenté '$codeLienParente' invalide !"); + } + + // Validation Sexe + if (!in_array($sexe, array("M", "F"))) { + $this->renvoyerErreurImport("Ligne $i : $nomComplet => Genre '$sexe' invalide !"); + } + + // Insertion en base temporaire + $this->beneficiaire->insererLigneModeleAssure($idAvenant, $categorie, $numeroAdherent, + $noFamille, $nom, $prenoms, $codeLienParente, $codeNaturePiece, $numeroPiece, $sexe, + $codeGroupeSanguin, $dateNaissance, $telephonePortable, $email); } - $nom = trim($tableauExcel[$i]['D']); - $prenoms = trim($tableauExcel[$i]['E']); - - $codeLienParente = trim($tableauExcel[$i]['F']); + $this->beneficiaire->gererIncorporationSurFamExistante(); - $codeNaturePiece = trim($tableauExcel[$i]['G']); - $numeroPiece = trim($tableauExcel[$i]['H']); - $sexe = trim($tableauExcel[$i]['I']); - $codeGroupeSanguin = trim($tableauExcel[$i]['J']); - $dateNaissance = trim($tableauExcel[$i]['K']); - $telephonePortable = trim($tableauExcel[$i]['L']); - $email = trim($tableauExcel[$i]['M']); - - $nomComplet = $nom . " " . $prenoms; - - if ( ($categorie<=" ") && ($codeLienParente=="A")) - { - $this->genererVueAjax(array('message_erreur_excel' => $nomComplet . " => Pas de catégorie!", 'succes_impot_execl' => "0")); - exit(); - } - - $liste_liens = array("A", "C", "E", "O"); - if (!in_array($codeLienParente, $liste_liens)) - { - $this->genererVueAjax(array('message_erreur_excel' => $nomComplet . " => Revoir lien de parenté!", 'succes_impot_execl' => "0")); - exit(); - } + // 3. Vérifications métier post-import + $this->verifierContraintesMetier(); - $liste_sexes = array("M", "F"); - if (!in_array($sexe, $liste_sexes)) - { - $this->genererVueAjax(array('message_erreur_excel' => $nomComplet . " => Revoir le sexe!", 'succes_impot_execl' => "0")); - exit(); - } + // 4. SUCCÈS FINAL + $this->genererVueAjax(array( + 'message_erreur_excel' => "Fichier analysé avec succès ! Préparation de l'incorporation...", + 'succes_impot_execl' => "1" + )); - // Penser à gérer les erreurs de date - - $this->beneficiaire->insererLigneModeleAssure($idAvenant, $categorie, $numeroAdherent, - $noFamille, $nom, $prenoms, $codeLienParente, $codeNaturePiece, $numeroPiece, $sexe, - $codeGroupeSanguin, $dateNaissance, $telephonePortable, $email); - - /* - echo "Ligne ". $i . " => OK"; - echo "
"; - */ + } catch (Exception $e) { + $this->renvoyerErreurImport("Erreur lors de la lecture du fichier : " . $e->getMessage()); } - - $this->beneficiaire->gererIncorporationSurFamExistante(); - - // Vérification de certaines erreurs : - // 1 => Si nouvelle famille sans Adhérent - $noFamilleSansAdherent = $this->beneficiaire->getadhimpfamillesansadherent(); - if ($noFamilleSansAdherent>"0") - { - $this->genererVueAjax(array('message_erreur_excel' => "Famille " . $noFamilleSansAdherent . " => Adherent Principal manquant !", 'succes_impot_execl' => "0")); - exit(); - } - - // 2 => Si plus d'1 Adhérent dans une même famille - $noFamillePlusieursAdherent = $this->beneficiaire->getadhimpfamilleplusieursadherent(); - if ($noFamillePlusieursAdherent>"0") - { - $this->genererVueAjax(array('message_erreur_excel' => "Famille " . $noFamillePlusieursAdherent . " => Plusieurs Adherents Principaux !", 'succes_impot_execl' => "0")); - exit(); - } - - // 3 => Incorporation sur une ancienne famille introuvable dans la police - $noFamilleExistantSansAdherent = $this->beneficiaire->getadhimpfamilleexistantsansadherent(); - if ($noFamilleExistantSansAdherent>"0") - { - $this->genererVueAjax(array('message_erreur_excel' => "Famille " . $noFamilleExistantSansAdherent . " => Ancienne famille introuvable !", 'succes_impot_execl' => "0")); - exit(); - } - - $this->genererVueAjax(array('message_erreur_excel' => "Fichier temporaire extrait du serveur avec succes!", 'succes_impot_execl' => "1")); - exit(); } - + + /** + * Helper pour uniformiser les sorties d'erreur + */ + private function renvoyerErreurImport($message) { + $this->genererVueAjax(array( + 'message_erreur_excel' => $message, + 'succes_impot_execl' => "0" + )); + exit(); + } + + /** + * Regroupe vos vérifications de cohérence famille + */ + private function verifierContraintesMetier() { + $err1 = $this->beneficiaire->getadhimpfamillesansadherent(); + if ($err1 > "0") $this->renvoyerErreurImport("Famille $err1 => Adhérent Principal (A) manquant !"); + + $err2 = $this->beneficiaire->getadhimpfamilleplusieursadherent(); + if ($err2 > "0") $this->renvoyerErreurImport("Famille $err2 => Plusieurs Adhérents Principaux détectés !"); + + $err3 = $this->beneficiaire->getadhimpfamilleexistantsansadherent(); + if ($err3 > "0") $this->renvoyerErreurImport("Famille $err3 => Ancienne famille introuvable dans cette police !"); + } + // public function traiterlignesimportees() { diff --git a/Js/fonctions.js b/Js/fonctions.js index 1a53cfe..d240137 100755 --- a/Js/fonctions.js +++ b/Js/fonctions.js @@ -199,6 +199,8 @@ function alert_ebene(p_msg, p_msg_eng) { }); } */ + +/* function alert_ebene(p_msg, p_msg_eng) { codeLangue = $("#codeLangue").val(); @@ -212,6 +214,45 @@ function alert_ebene(p_msg, p_msg_eng) alert(p_msg); } } + */ + +function alert_ebene(msgFr, msgEn) { + const codeLangue = document.querySelector("#codeLangue")?.value || "fr_FR"; + const message = (codeLangue === "en_US") ? msgEn : msgFr; + + // Bloquant : l'utilisateur doit cliquer sur OK + window.alert(message); +} + +/* +function alert_ebene(p_msg, p_msg_eng) { + const codeLangue = document.querySelector("#codeLangue")?.value || "fr_FR"; + const message = (codeLangue === "en_US") ? p_msg_eng : p_msg; + + return Swal.fire({ + text: message, + icon: 'info', + confirmButtonText: (codeLangue === "en_US") ? 'OK' : 'D\'accord' + }).then(() => { + // Ici tu mets l'action suivante, elle ne s'exécute qu'après clic sur OK + console.log("Utilisateur a validé le message"); + }); +} + */ + + +/* +function alert_ebene(msgFr, msgEn) { + const codeLangue = document.querySelector("#codeLangue")?.value || "fr_FR"; + const message = (codeLangue === "en_US") ? msgEn : msgFr; + + return Swal.fire({ + text: message, + icon: 'info', + confirmButtonText: (codeLangue === "en_US") ? 'OK' : 'D\'accord' + }); +} +*/ /** @@ -1397,7 +1438,7 @@ function enregistrer_avenant() alert_ebene(v_msg, v_msgEng); return; - } + } motifavenant=$("#motifavenant").val(); @@ -1489,7 +1530,7 @@ function recapituler_retrait() oTable.destroy(); setTimeout(function() { - appliquerDataTable(); + appliquerDataTable('.tabliste'); }, 500); }, error: function(data) { @@ -2552,6 +2593,8 @@ function init_importer_modele_assure() { * ETAPE 3 (Action) : Liaison du fichier à l'avenant choisi */ function importer_modele_assure(idAvenant) { + debugger; + // On re-vérifie la présence du fichier par sécurité var cheminFichier = $("#cheminFichier").val(); if (!cheminFichier || cheminFichier === "") { @@ -2574,23 +2617,28 @@ function importer_modele_assure(idAvenant) { type: 'POST', data: donnees, success: function(data) { - // Le serveur doit retourner un flag de succès dans le HTML - // ex: - $("#div_erreur_excel").html(data); - - var isSuccess = $("#succes_impot_execl").val(); - - maj_etape_3_import_assures(); - /* - if (isSuccess === "1") { - alert_ebene("Liaison réussie ! Passage au traitement...", "Link successful! Moving to processing..."); - maj_etape_3_import_assures(); - } else { - div_export.empty(); // On vide le spinner pour laisser voir l'erreur - alert_ebene("Le fichier contient des erreurs de format.", "The file contains formatting errors."); - } - */ - }, + debugger; + // 1. On injecte d'abord le contenu dans le div + $("#div_erreur_excel").html(data); + + // 2. On cherche l'input spécifiquement DANS le contenu qu'on vient de recevoir + // On utilise .find() si l'input est à l'intérieur d'un div, + // ou .filter() s'il est à la racine du HTML renvoyé. + var isSuccess = $(data).filter("#succes_impot_execl").val() || $(data).find("#succes_impot_execl").val(); + + console.log("Valeur détectée :", isSuccess); // Pour votre débogage + + if (isSuccess === "1") { + alert_ebene("Opération terminée avec succès!", "Operation completed successfully!"); + // On attend un tout petit peu que le DOM soit stable avant de passer à la suite + setTimeout(function(){ + maj_etape_3_import_assures(); + }, 500); + } else { + div_export.html(''); // On cache le spinner + // Le message d'erreur est déjà affiché par $("#div_erreur_excel").html(data) + } + }, error: function() { alert_ebene("Erreur technique lors de l'importation.", "Technical error during import."); } @@ -2897,21 +2945,23 @@ function ajouter_sans_college_adherent_importe_college() v_msg="Attention! Confirmez-vous cette opération?"; v_msgEng="Warning! Do you confirm this operation?"; - if(confirm_ebene(v_msg, v_msgEng)) - { - $.ajax({ - url: $("#racineWeb").val()+"Ajaximporterlisteassure/ajoutersanscollegeadherentaucollege/", - type: 'POST', - data: donnees, - success: function(data) { - }, - error: function(data) { - }, - complete: function() { - afficher_adherent_importee(); - } - }); + confirm_ebene(v_msg, v_msgEng).then(isConfirmed => { + if (isConfirmed) { + $.ajax({ + url: $("#racineWeb").val()+"Ajaximporterlisteassure/ajoutersanscollegeadherentaucollege/", + type: 'POST', + data: donnees, + success: function(data) { + }, + error: function(data) { + }, + complete: function() { + afficher_adherent_importee(); + } + }); } + }); + } @@ -2933,21 +2983,22 @@ function retirer_tous_adherent_importe_college() v_msg="Attention, cela va vider ce collège! Confirmez-vous?"; v_msgEng="Attention, this will empty this college! Do you confirm?"; - if(confirm_ebene(v_msg, v_msgEng)) - { - $.ajax({ - url: $("#racineWeb").val()+"Ajaximporterlisteassure/retirertousadherentaucollege/", - type: 'POST', - data: donnees, - success: function(data) { - }, - error: function(data) { - }, - complete: function() { - afficher_adherent_importee(); - } - }); + confirm_ebene(v_msg, v_msgEng).then(isConfirmed => { + if (isConfirmed) { + $.ajax({ + url: $("#racineWeb").val()+"Ajaximporterlisteassure/retirertousadherentaucollege/", + type: 'POST', + data: donnees, + success: function(data) { + }, + error: function(data) { + }, + complete: function() { + afficher_adherent_importee(); + } + }); } + }); } function incorporer_assures_inmportes() @@ -3206,8 +3257,17 @@ function afficher_beneficiare_prime_adherent() donnees_retour = ""; donnees = 'debutPeriode='+debutPeriode+"&finPeriode="+finPeriode; - $("#div_detail_requete").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); - + $("#div_detail_requete").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); + $.ajax({ url: $("#racineWeb").val()+"Ajaxbeneficiaireprimeadherent/", type : 'post', @@ -3230,7 +3290,16 @@ function rapport_sp_police() function sinistres_a_prime_police() { - $("#div_detail_sp").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); + $("#div_detail_sp").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); $.ajax({ url: $("#racineWeb").val()+"Ajaxsppolice/police/", @@ -3247,7 +3316,16 @@ function sinistres_a_prime_police() function sinistres_a_prime_categorie() { - $("#div_detail_sp").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); + $("#div_detail_sp").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); $.ajax({ url: $("#racineWeb").val()+"Ajaxsppolice/categorie/", @@ -3265,7 +3343,16 @@ function sinistres_a_prime_categorie() function sinistres_a_prime_college() { - $("#div_detail_sp").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); + $("#div_detail_sp").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); $.ajax({ url: $("#racineWeb").val()+"Ajaxsppolice/college/", @@ -3285,10 +3372,17 @@ function requetes_synthese_consommation_police() { v_url = $("#racineWeb").val()+"Ajaxsyntheseconsopolice/"; - $("#div_detail_exp").html(''); + $("#div_detail_sp").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); - $("#div_detail_sp").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); - $.ajax({ url: v_url, type : 'post', @@ -3311,7 +3405,16 @@ function requetes_synthese_consommation_police_export() { v_url = $("#racineWeb").val()+"Ajaxsyntheseconsopolice/exportxls/"; - $("#div_detail_exp").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); + $("#div_detail_exp").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); $.ajax({ url: v_url, @@ -3337,8 +3440,17 @@ function lister_ged_police() donnees = 'd1='+d1+'&d2='+d2+'&nomOrigine='+nomOrigine; - $("#div_ged").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); - + $("#div_ged").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); + $.ajax({ url: $("#racineWeb").val()+"Ajaxlistegedpolice/", type : 'post', @@ -3377,7 +3489,17 @@ function imprimer_liste_assures_date() donnees = 'dateAnalyse='+dateAnalyse; var div_export = $('#div_export_assures'); - div_export.html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); + + div_export.html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); $.ajax({ url: $("#racineWeb").val()+"Ajaximprimerlisteassure/", @@ -3420,7 +3542,17 @@ function exporter_liste_assures_date() donnees = 'dateAnalyse='+dateAnalyse; var div_export = $('#div_exporter_liste_assures'); - div_export.html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); + + div_export.html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); $.ajax({ url: $("#racineWeb").val()+"Ajaxexporterlisteassure/", @@ -3464,7 +3596,16 @@ function liste_mouvemements_assures() donnees += '&valide='+valide; donnees += '&debut='+debut+'&fin='+fin; - $("#div_mvt").html('
  ' + 'Veuillez patienter... / Please wait...' + '
'); + $("#div_mvt").html(` +
+
+ Loading... +
+ + Veuillez patienter... / Please wait... + +
+ `); $.ajax({ url: $("#racineWeb").val()+"Ajaxmouvementassure/", @@ -3474,8 +3615,23 @@ function liste_mouvemements_assures() }, success: function(data) { $("#div_mvt").html(data); + appliquerDataTable('.tabliste'); }, complete: function() { } }); } + +function retour_fiche_police() +{ + + idPolice=$("#idPolice_C" ).val(); + + if (idPolice>"") + { + window.location.assign($("#racineWeb" ).val()+"Fichepolice/"); + }else{ + window.location.assign($("#racineWeb" ).val()+"Accueil/"); + } + +} \ No newline at end of file diff --git a/Modele/Mouvementassure.php b/Modele/Mouvementassure.php index b9bb50b..3aae6e7 100644 --- a/Modele/Mouvementassure.php +++ b/Modele/Mouvementassure.php @@ -10,8 +10,10 @@ class Mouvementassure extends Modele { $sql = 'call sp_get_mouvementassures(?, ?, ?, ?, ?)'; - // var_dump(array($codeSensMouvement, $valide, $debut, $fin)); - // exit(); + /* + var_dump(array($_SESSION['idPolice_C'], $codeSensMouvement, $valide, $debut, $fin)); + exit(); + */ $resultat = $this->executerRequete($sql, array($_SESSION['idPolice_C'], $codeSensMouvement, $valide, $debut, $fin)); diff --git a/Vue/Ajaximporterlisteassure/afficheradherentimportee.php b/Vue/Ajaximporterlisteassure/afficheradherentimportee.php index 44d6bb3..dbdd656 100644 --- a/Vue/Ajaximporterlisteassure/afficheradherentimportee.php +++ b/Vue/Ajaximporterlisteassure/afficheradherentimportee.php @@ -1,102 +1,133 @@ -
+
+
+ +
+
+
+
+ +
+ +
+
+
+ +
+
+ +
+
-
-
- - - - - - - - - - - - - - +
+
=>
+ + + + + + + + + + + + + + + + + + +
Action
+
nettoyer($adherent['categorie']) ?>
+
+ nettoyer($adherent['codeProduit']) ?: 'N/A' ?> +
+
+ nettoyer($adherent['noFamille']) ?> +
nettoyer($adherent['numeroAdherent']) ?>
+
+
nettoyer($adherent['nom']) ?>
+
nettoyer($adherent['prenoms']) ?>
+
+ +
+
+
+
+
- +
+
+
+
+ +
- - - - +
+
+ +
- - +
+ + + + + + + + + + + + + + + + + + + +
Retirer
+ + +
nettoyer($adh_c['categorie']) ?>
+
nettoyer($adh_c['libelleCollege']) ?>
+
+ nettoyer($adh_c['noFamille']) ?> + +
nettoyer($adh_c['nom']) ?> nettoyer($adh_c['prenoms']) ?>
+
+
+
+
+
- - - nettoyer($adherent['categorie']) ?> - - '0'): ?> - nettoyer($adherent['libelleCollege']) ?> - nettoyer($adherent['codeProduit']) ?> - - nettoyer($adherent['libelleCollege']) ?> - nettoyer($adherent['codeProduit']) ?> - - - - nettoyer($adherent['numeroAdherent']) ?> - nettoyer($adherent['noFamille']) ?> - - nettoyer($adherent['nom']) ?> - nettoyer($adherent['prenoms']) ?> - - - - - - -
+
+
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
<=
nettoyer($adherent_college['categorie']) ?>nettoyer($adherent_college['libelleCollege']) ?>nettoyer($adherent_college['codeProduit']) ?>nettoyer($adherent_college['numeroAdherent']) ?>nettoyer($adherent_college['noFamille']) ?>nettoyer($adherent_college['nom']) ?>nettoyer($adherent_college['prenoms']) ?>
-
-
- - + \ No newline at end of file diff --git a/Vue/Ajaximporterlisteassure/importermodele.php b/Vue/Ajaximporterlisteassure/importermodele.php index 36c8fc4..b088579 100644 --- a/Vue/Ajaximporterlisteassure/importermodele.php +++ b/Vue/Ajaximporterlisteassure/importermodele.php @@ -1,4 +1,9 @@ -
-

- +
+ +
+
+ +
+ + \ No newline at end of file diff --git a/Vue/Ajaximporterlisteassure/initimportermodele.php b/Vue/Ajaximporterlisteassure/initimportermodele.php index a900efc..e57d61e 100644 --- a/Vue/Ajaximporterlisteassure/initimportermodele.php +++ b/Vue/Ajaximporterlisteassure/initimportermodele.php @@ -1,32 +1,66 @@ - +
+
+ +
+ +
+
- - - - - - - - - - - - +
+
+ + + + + + + + + + + + + + + + + + + + + + +
+ nettoyer($avenant['numeroAvenant']) ?> + + + nettoyer($avenant['dateEffet'])) ?> + + +
nettoyer($avenant['libelleAvenant']) ?>
+
+ Saisie le nettoyer($avenant['dateSysteme'])) ?> +
+
+
+ nettoyer($avenant['motifavenant']) ?: '-' ?> +
+
+ nettoyer($avenant['utilisateur']) ?> + + +
+
+
- - - - nettoyer($avenant['numeroAvenant']) ?> - nettoyer($avenant['dateEffet'])) ?> - nettoyer($avenant['libelleAvenant']) ?> - nettoyer($avenant['motifavenant']) ?> - nettoyer($avenant['utilisateur']) ?> - nettoyer($avenant['dateSysteme'])) ?> - - - - - + \ No newline at end of file diff --git a/Vue/Ajaxlistegedpolice/index.php b/Vue/Ajaxlistegedpolice/index.php index cfe044e..63d49b2 100644 --- a/Vue/Ajaxlistegedpolice/index.php +++ b/Vue/Ajaxlistegedpolice/index.php @@ -1,39 +1,42 @@ -
- " ")) : ?> - - - - - - - - - - - - - - - +
+
Date Src Document
+ + + + + + + + - - nettoyer($ged['idGed']); + nettoyer($ged['cheminFichier']); ?> - - - - - - - - - - - + + + + + diff --git a/Vue/Ajaxmouvementassure/index.php b/Vue/Ajaxmouvementassure/index.php index 62e4551..001b302 100644 --- a/Vue/Ajaxmouvementassure/index.php +++ b/Vue/Ajaxmouvementassure/index.php @@ -1,43 +1,92 @@ -
nettoyer($ged['dateSysteme'])) ?>nettoyer($ged['source']) ?>nettoyer($ged['souscripteur']) ?>nettoyer($ged['numeroPolice']) ?>nettoyer($ged['prestataire']) ?>nettoyer($ged['adherent']) ?>nettoyer($ged['numeroBeneficiaire']) ?>nettoyer($ged['beneficiaire']) ?>nettoyer($ged['nomOrigine']) ?> - +
+
nettoyer($ged['dateSysteme'])) ?>
+
nettoyer($ged['souscripteur']) ?>
+
+ nettoyer($ged['source']) ?> + +
nettoyer($ged['numeroPolice']) ?>
+
+ nettoyer($ged['numeroBeneficiaire']) ?> - nettoyer($ged['beneficiaire']) ?> +
+
nettoyer($ged['adherent']) ?>
+
+
+ nettoyer($ged['nomOrigine']) ?> +
+
+ + +
- - - - - - - - - - - - - - - - - nettoyer($mvt['id']); - $valide = $this->nettoyer($mvt['valide']); - $libelleSensMouvement = est_anglophone() ? $mvt['libelleSensMouvementEng'] : $mvt['libelleSensMouvement']; - ?> - - - - - - - - - - - - - - - - - - - - -
Mvt
nettoyer($mvt['dateEffet']), $_SESSION['lang']) ?> nettoyer($mvt['codeUtilisateur']) ?>nettoyer($mvt['adherent']) ?>nettoyer($mvt['beneficiaire']) ?>nettoyer($mvt['numeroBeneficiaire']) ?>nettoyer($mvt['codeLienParente']) ?>nettoyer($mvt['dateSysteme'])) ?> nettoyer($mvt['dateValidation'])) ?>nettoyer($mvt['userValidation']) ?>
\ No newline at end of file +
+ + + + + + + + + + + + + + + + nettoyer($mvt['id']); + $valide = $this->nettoyer($mvt['valide']); + $sensMvt = $mvt['sensMouvement']; // On suppose que '0' = Entrée, '1' = Sortie + + $libelleSensMouvement = est_anglophone() ? $mvt['libelleSensMouvementEng'] : $mvt['libelleSensMouvement']; + + //var_dump($codeMvt, $libelleSensMouvement); + ?> + + + + + + + + + + + + + + + + + + + +
+ nettoyer($mvt['dateEffet']), $_SESSION['lang']) ?> + + + + + + + + + + + +
nettoyer($mvt['beneficiaire']) ?>
+
nettoyer($mvt['numeroBeneficiaire']) ?>
+
+ nettoyer($mvt['adherent']) ?> + + nettoyer($mvt['codeLienParente']) ?> + +
nettoyer($mvt['dateSysteme'])) ?>
+
nettoyer($mvt['codeUtilisateur']) ?>
+
+ + + + + + + + + + + +
nettoyer($mvt['userValidation']) ?>
+
nettoyer($mvt['dateValidation'])) ?>
+ + + +
+
+ + \ No newline at end of file diff --git a/Vue/Ajaxsppolice/categorie.php b/Vue/Ajaxsppolice/categorie.php index 459fbe3..0c7e5bb 100644 --- a/Vue/Ajaxsppolice/categorie.php +++ b/Vue/Ajaxsppolice/categorie.php @@ -1,31 +1,65 @@ -
+
+ +
+ +
+
- " disabled > +
+
+ + + + + + + + + + + -
- - - - - - - - - - + + = 100) ? 'text-danger fw-bold' : (($ratio >= 75) ? 'text-warning fw-bold' : 'text-success fw-bold'); + $progressColor = ($ratio >= 100) ? 'bg-danger' : (($ratio >= 75) ? 'bg-warning' : 'bg-success'); + ?> + + - - - - - - - - - - - - -
Cat
+ nettoyer($sppolice['codeProduit']) ?> +
nettoyer($sppolice['codeProduit']) ?> nettoyer($sppolice['primestat'])) ?> nettoyer($sppolice['prime_acquise'])) ?> nettoyer($sppolice['consommation'])) ?> nettoyer($sppolice['rapportsp']) ?> nettoyer($sppolice['rapportspgeneral']) ?>
-
+ nettoyer($sppolice['primestat'])) ?> + nettoyer($sppolice['prime_acquise'])) ?> + + + nettoyer($sppolice['consommation'])) ?> + + + +
+ nettoyer($sppolice['rapportsp']) ?> % +
+
+
+
+ + + + nettoyer($sppolice['rapportspgeneral']) ?> % + + + + + +
+
+
+ + \ No newline at end of file diff --git a/Vue/Ajaxsppolice/college.php b/Vue/Ajaxsppolice/college.php index b005e6a..0ea1298 100644 --- a/Vue/Ajaxsppolice/college.php +++ b/Vue/Ajaxsppolice/college.php @@ -1,32 +1,72 @@ -
+
+ +
+ +
+
- " disabled > +
+
+ + + + + + + + + + + -
- - - - - - - - - - + + = 100) { $bgRatio = 'bg-danger'; $textRatio = 'text-danger'; } + elseif ($ratio >= 80) { $bgRatio = 'bg-warning'; $textRatio = 'text-warning'; } + ?> + + + + - - - - - - - - - - - - - -
+ nettoyer($sppolice['codeProduit']) ?> + + nettoyer($sppolice['libelleCollege']) ?> +
nettoyer($sppolice['codeProduit']) ?> nettoyer($sppolice['libelleCollege']) ?> nettoyer($sppolice['primestat'])) ?> nettoyer($sppolice['prime_acquise'])) ?> nettoyer($sppolice['consommation'])) ?> nettoyer($sppolice['rapportsp']) ?> nettoyer($sppolice['rapportspgeneral']) ?>
-
+ nettoyer($sppolice['primestat'])) ?> + nettoyer($sppolice['prime_acquise'])) ?> + nettoyer($sppolice['consommation'])) ?> + + +
+ nettoyer($sppolice['rapportsp']) ?>% +
+
+
+
+ + + + nettoyer($sppolice['rapportspgeneral']) ?>% + + + + + +
+
+
+ + \ No newline at end of file diff --git a/Vue/Ajaxsppolice/police.php b/Vue/Ajaxsppolice/police.php index 2b62abe..5bae70b 100644 --- a/Vue/Ajaxsppolice/police.php +++ b/Vue/Ajaxsppolice/police.php @@ -1,26 +1,79 @@ -
+
+
+
+ +
+ +
- " disabled > +
+
+
+
+
+

nettoyer($sppolice['primestat'])) ?>

+
+
+
+
- - - - - - - - - - +
+
+
+
+

nettoyer($sppolice['prime_acquise'])) ?>

+
+
+
+
- - - - - - - - - -
nettoyer($sppolice['primestat'])) ?> nettoyer($sppolice['prime_acquise'])) ?> nettoyer($sppolice['consommation'])) ?> nettoyer($sppolice['rapportsp']) ?> nettoyer($sppolice['rapportspgeneral']) ?>
-
+
+
+
+
+

nettoyer($sppolice['consommation'])) ?>

+
+
+
+
+
+ +
+
+ 80 ? 'danger' : ($sp_acquis > 60 ? 'warning' : 'success'); + ?> +
+
+
+
+

nettoyer($sppolice['rapportsp']) ?> %

+
+
+ +
+
+
+
+ +
+
+
+
+
+

nettoyer($sppolice['rapportspgeneral']) ?> %

+
+
+ +
+
+
+
+
+
+ + \ No newline at end of file diff --git a/Vue/Ajaxsyntheseconsopolice/index.php b/Vue/Ajaxsyntheseconsopolice/index.php index 4a785a1..1130207 100644 --- a/Vue/Ajaxsyntheseconsopolice/index.php +++ b/Vue/Ajaxsyntheseconsopolice/index.php @@ -1,63 +1,142 @@ -
- - - - +titre = "INTER-SANTE - Synthèse Consommations"; + // Initialisation des totaux pour le footer + $totStat = $totTtc = $totAll = 0; + $natures = ['OUT', 'INP', 'OPT', 'MON', 'DEN', 'FUN']; + $totPlafonds = array_fill_keys($natures, 0); + $totConsos = array_fill_keys($natures, 0); +?> - + - - - - -
nettoyer($conommation['consommation_ALL'])) ?>
-
\ No newline at end of file +
+ +
+ +
+

+

Police: | Date:

+
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
N° AdhStatTTCTOTAL
nettoyer($conso['nomAdherent']) ?>nettoyer($conso['numeroAdherent']) ?> + +
:
+
+
+
+ + \ No newline at end of file diff --git a/Vue/Gedpolice/index.php b/Vue/Gedpolice/index.php index 84d6a96..5d92cc4 100644 --- a/Vue/Gedpolice/index.php +++ b/Vue/Gedpolice/index.php @@ -1,89 +1,125 @@ -titre = "INTER-SANTE - GED Police"; +titre = "INTER-SANTE - GED Police"; ?> - /* - var_dump - ( - array( - "cheminGed" => $_SESSION['cheminGed'], - "lienRh" => $_SESSION['lienRh_C'], - "dossierGed" => $_SESSION['dossierGed'], - ) - ); - */ -?> +
+

- Limité à 50 documents => Filtrer sur période pour obtenir le résultat souhaité") ?> +
+

+ : + nettoyer($_SESSION['numeroPolice_C']) ?> +

+ + + +
-
- - - - - + " ")) : ?> + + - - +
+
+
+
+
+
+
+
+ +
+ + +
+
+ + +
+ + + + + +
-
- +
- - - - - - - + + +
+ +
+
+ + + + + - - - - -
Doc
" />
- +
+
+
+ + + + + + + + + + + + nettoyer($ged['cheminFichier']); + ?> + + + + + + + + + +
+
nettoyer($ged['dateSysteme'])) ?>
+
nettoyer($ged['souscripteur']) ?>
+
+ nettoyer($ged['source']) ?> + +
nettoyer($ged['numeroPolice']) ?>
+
+ nettoyer($ged['numeroBeneficiaire']) ?> - nettoyer($ged['beneficiaire']) ?> +
+
nettoyer($ged['adherent']) ?>
+
+
+ nettoyer($ged['nomOrigine']) ?> +
+
+ + + +
+
+
+
+
+
- -
- " ")) : ?> - - - - - - - - - - - - - - - - - - - nettoyer($ged['idGed']); - $cheminFichier = $this->nettoyer($ged['cheminFichier']); - ?> - - - - - - - - - - - - - - -
Date Src Document
nettoyer($ged['dateSysteme'])) ?>nettoyer($ged['source']) ?>nettoyer($ged['souscripteur']) ?>nettoyer($ged['numeroPolice']) ?>nettoyer($ged['prestataire']) ?>nettoyer($ged['adherent']) ?>nettoyer($ged['numeroBeneficiaire']) ?>nettoyer($ged['beneficiaire']) ?>nettoyer($ged['nomOrigine']) ?> - -
-
+ \ No newline at end of file diff --git a/Vue/Importassure/index.php b/Vue/Importassure/index.php index 60f1df8..5d30041 100644 --- a/Vue/Importassure/index.php +++ b/Vue/Importassure/index.php @@ -1,5 +1,7 @@ nettoyer($police['etatPolice']); + $codeEtat = $this->nettoyer($police['codeEtatPolice']); + ?>
@@ -20,9 +22,9 @@
- + - + diff --git a/Vue/Liercolleges/index.php b/Vue/Liercolleges/index.php index 069c0ab..2afdd47 100644 --- a/Vue/Liercolleges/index.php +++ b/Vue/Liercolleges/index.php @@ -1,20 +1,51 @@ -titre = "INTER-SANTE - Lier collèges"; ?> +
+ +

- +
+
+
+
+ +
+
+
+ + + + +
+
+
+
+ +
+
+
+
+
- - - - - - - - -
- -
+
+
+ +

+
+
+
-
-
+ \ No newline at end of file diff --git a/Vue/Listeimportassure/index.php b/Vue/Listeimportassure/index.php index c73c4cf..61fb278 100644 --- a/Vue/Listeimportassure/index.php +++ b/Vue/Listeimportassure/index.php @@ -1,118 +1,151 @@ -titre = "INTER-SANTE - Liste Assurés Importés"; -?> +titre = "INTER-SANTE - " . _("Validation Importation"); ?> - +
+
+
+
+
+
+

+ +
+
+
+
+
+
+
+
+
+

+ +
+
+
+
+
+
+
+
+
+

+ FCFA +
+
+
+
+
- - +
+
+
+ + + + + + + + + + + + + + + + + +
+
+
+
- " . _("Lignes Totales") . " => " . $nb_ligne_ass . " => " . _("Lignes sans collège") . " => " . $nb_adh ?> +
+
+
+
+ + +
+
+ +
+ 0): ?> +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
nettoyer($beneficiaire['categorie']) ?>
+
+ nettoyer($beneficiaire['libelleCollege']) ?: _("Collège manquant") ?> + | nettoyer($beneficiaire['codeProduit']) ?> +
+
+
nettoyer($beneficiaire['noFamille']) ?>
+
nettoyer($beneficiaire['numeroAdherent']) ?>
+
+
nettoyer($beneficiaire['nom']) ?>
+
nettoyer($beneficiaire['prenoms']) ?>
+
+ nettoyer($beneficiaire['codeLienParente']) ?> +
nettoyer($beneficiaire['sexe']) ?>
+
+
nettoyer($beneficiaire['dateNaissance'])) ?>
+
nettoyer($beneficiaire['dateEffet'])) ?>
+
nettoyer($beneficiaire['primeHt'])) ?>nettoyer($beneficiaire['primeTtc'])) ?> + +
+
+ +
+ +

+
+ +
+
+
-
+ + + - '0'): ?> - - +
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - '0'): ?> - - - - - - - - - - - - - - - - - - - - - - - - -
nettoyer($dbeneficiaires_total['nbLigne'])) ?> nettoyer($dbeneficiaires_total['primeHtTotal'])) ?>nettoyer($dbeneficiaires_total['taxeTotal'])) ?>nettoyer($dbeneficiaires_total['fraisCarteTotal'])) ?>nettoyer($dbeneficiaires_total['primeTtcTotal'])) ?>nettoyer($dbeneficiaires_total['primeNetteStatTotal'])) ?>
Sex - - Stat
nettoyer($dbeneficiaires_total['nbLigne'])) ?> nettoyer($dbeneficiaires_total['primeHtTotal'])) ?>nettoyer($dbeneficiaires_total['taxeTotal'])) ?>nettoyer($dbeneficiaires_total['fraisCarteTotal'])) ?>nettoyer($dbeneficiaires_total['primeTtcTotal'])) ?>nettoyer($dbeneficiaires_total['primeNetteStatTotal'])) ?>
nettoyer($beneficiaire['categorie']) ?>nettoyer($beneficiaire['libelleCollege']) ?>nettoyer($beneficiaire['codeProduit']) ?>nettoyer($beneficiaire['libelleCollege']) ?>nettoyer($beneficiaire['codeProduit']) ?>nettoyer($beneficiaire['numeroAdherent']) ?>nettoyer($beneficiaire['noFamille']) ?>nettoyer($beneficiaire['nom']) ?>nettoyer($beneficiaire['prenoms']) ?>nettoyer($beneficiaire['codeLienParente']) ?>nettoyer($beneficiaire['sexe']) ?>nettoyer($beneficiaire['dateNaissance'])) ?>nettoyer($beneficiaire['dateEffet'])) ?>nettoyer($beneficiaire['primeHt'])) ?>nettoyer($beneficiaire['taxe'])) ?>nettoyer($beneficiaire['fraisCarte'])) ?>nettoyer($beneficiaire['primeTtc'])) ?>nettoyer($beneficiaire['primeNetteStat'])) ?>
- - -
-

-
- - -
- -
-
- + \ No newline at end of file diff --git a/Vue/Mouvementassure/index.php b/Vue/Mouvementassure/index.php index bcf8c26..5fb687c 100644 --- a/Vue/Mouvementassure/index.php +++ b/Vue/Mouvementassure/index.php @@ -1,35 +1,63 @@ -titre = "Intersanté - Mouvements sur les assurés"; -?> +titre = "Intersanté - Mouvements sur les assurés"; ?> - - - - - - - - - - +
+
+
+ +
+ +
+ + + + +
+
-
- - - - - - -
Période du +
+ +

-
au Etat - - - -
+
+ + +
-
+
+ + +
+ +
+
+ +
+
+ + + + +
+
+ +

+
+
+ + + \ No newline at end of file diff --git a/Vue/Nonfacturepolice/index.php b/Vue/Nonfacturepolice/index.php index 8c09eab..1c685e2 100644 --- a/Vue/Nonfacturepolice/index.php +++ b/Vue/Nonfacturepolice/index.php @@ -1,58 +1,87 @@ +
+ +

- nettoyer($_SESSION['numeroPolice_C'])?> +
+

+ : nettoyer($_SESSION['numeroPolice_C']) ?> +

+
- - - - - - - - - - +
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
- - - - - - - - - +
+
+
Total nettoyer($ente_nonfacture['nbLignesTotal'])) ?>nettoyer($ente_nonfacture['primeHtTotal'])) ?>nettoyer($ente_nonfacture['taxeTotal'])) ?>nettoyer($ente_nonfacture['fraisCarteTotal'])) ?>nettoyer($ente_nonfacture['primeTtcTotal'])) ?>
- -
+ + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + nettoyer($nonfacture['dateEffet'])) ?> + + +
+
+ + - - - Total - nettoyer($ente_nonfacture['nbLignesTotal'])) ?> - nettoyer($ente_nonfacture['primeHtTotal'])) ?> - nettoyer($ente_nonfacture['taxeTotal'])) ?> - nettoyer($ente_nonfacture['fraisCarteTotal'])) ?> - nettoyer($ente_nonfacture['primeTtcTotal'])) ?> - - - - - - nettoyer($nonfacture['dateEffet'])) ?> - nettoyer($nonfacture['nbLignes'])) ?> - nettoyer($nonfacture['primeHt'])) ?> - nettoyer($nonfacture['taxe'])) ?> - nettoyer($nonfacture['fraisCarte'])) ?> - nettoyer($nonfacture['primeTtc'])) ?> - - - - + \ No newline at end of file diff --git a/Vue/Sppolice/index.php b/Vue/Sppolice/index.php index 3c2763c..83a63fa 100644 --- a/Vue/Sppolice/index.php +++ b/Vue/Sppolice/index.php @@ -1,40 +1,100 @@ titre = "INTER-SANTE - Rapport S/P police"; ?> - nettoyer($_SESSION['numeroPolice_C'])?> +
+ +

- - - - - - - - - - +
+

+ : + nettoyer($_SESSION['numeroPolice_C']) ?> +

+
+ : nettoyer($sppoliceentete['dureePolice']) ?> +
+
- +
+
+
+
+
+
+
+
+
nettoyer($sppoliceentete['dateEffet'])) ?>
+
+ +
+
+
nettoyer($sppoliceentete['dateEcheance'])) ?>
+
+
+
+
+
-
- - - - - - - -
nettoyer($sppoliceentete['dateEffet'])) ?> nettoyer($sppoliceentete['dateEcheance'])) ?> nettoyer($sppoliceentete['duree_acquise']) ?> nettoyer($sppoliceentete['ratio_acquise']) ?> nettoyer($sppoliceentete['dureePolice']) ?>
+
+
+
+
+

nettoyer($sppoliceentete['duree_acquise']) ?>

+ +
+
+
- - - - - - - - -
+
+ nettoyer($sppoliceentete['ratio_acquise']); + $color = $ratio > 100 ? 'danger' : ($ratio > 70 ? 'warning' : 'success'); + ?> +
+
+
+
+

%

+
+
+
+
+
+
+
+
-
- -
+
+
+
+
+ +
+
+ +
+
+ +
+
+
+
+ +
+
+ +

+
+
+ + + + \ No newline at end of file diff --git a/Vue/Syntheseconsopolice/index.php b/Vue/Syntheseconsopolice/index.php index d95761c..3d14e3c 100644 --- a/Vue/Syntheseconsopolice/index.php +++ b/Vue/Syntheseconsopolice/index.php @@ -1,49 +1,83 @@ -titre = "INTER-SANTE - SYNTHESE CONSOMMATIONS DE LA POLICE"; -?> - - nettoyer($_SESSION['numeroPolice_C'])?> - - - - - - - - - - - - - - - - - - - - - - -
nettoyer($sppoliceentete['dateEffet'])) ?> nettoyer($sppoliceentete['dateEcheance'])) ?> nettoyer($sppoliceentete['duree_acquise']) ?> nettoyer($sppoliceentete['ratio_acquise']) ?> nettoyer($sppoliceentete['dureePolice']) ?>
- - - - - - - - - - - - -
- -
+
-
+

-
- -
+
+

+ : nettoyer($_SESSION['numeroPolice_C']) ?> +

+
+ +
+
+
+
+
+
+
nettoyer($sppoliceentete['dateEffet'])) ?>
+
+ +
+
+
nettoyer($sppoliceentete['dateEcheance'])) ?>
+
+
+
+
+
+
+
+
+
nettoyer($sppoliceentete['duree_acquise']) ?> j
+
+
+
+
+
+
+
+ + nettoyer($sppoliceentete['ratio_acquise']),2) ?> % +
+
+
+
+
+
+
+
+ +
+
+
+
+ +
+
+ +
+
+
+
+ +
+
+
+ +

+
+
+ +
+ + \ No newline at end of file diff --git a/Vue/gabarit.php b/Vue/gabarit.php index 1ddffe5..748da34 100755 --- a/Vue/gabarit.php +++ b/Vue/gabarit.php @@ -638,7 +638,7 @@ $photoAssureCrypte = $_SESSION['photoAssureCrypte']; - +