diff --git a/Js/fonctions.js b/Js/fonctions.js index c813e00..8d67dea 100755 --- a/Js/fonctions.js +++ b/Js/fonctions.js @@ -2744,3 +2744,191 @@ function traiter_lignes_importees() afficher_liste_assures_a_importer(); } + +function afficher_adherent_importee() +{ + idCollege=$("#idCollege").val(); + + if (idCollege<=" ") + { + v_msg="Veuillez sélectionner un collège!"; + v_msgEng="Please select a college!"; + alert_ebene(v_msg, v_msgEng); + + return; + } + + donnees = 'idCollege='+idCollege; + + var div_attente = $('#div_adherents_importes'); + + div_attente.html('
  ' + 'Chargement en cours! Veuillez patienter...' + '
'); + + + $.ajax({ + url: $("#racineWeb").val()+"Ajaximporterlisteassure/afficheradherentimportee/", + type : 'post', + data: donnees, + error: function(errorData) { + }, + success: function(data) { + div_attente.html(data); + }, + complete: function() { + } + }); +} + +function retirer_un_adherent_importe_college(idBeneficiairemodel) +{ + donnees = 'idBeneficiairemodel='+idBeneficiairemodel; + + $.ajax({ + url: $("#racineWeb").val()+"Ajaximporterlisteassure/retirerunadherentaucollege/", + type: 'POST', + data: donnees, + success: function(data) { + }, + error: function(data) { + }, + complete: function() { + afficher_adherent_importee(); + } + }); +} + +function ajouter_un_adherent_importe_college(idBeneficiairemodel) +{ + idCollege=$("#idCollege").val(); + + if (idCollege<=" ") + { + v_msg="Veuillez sélectionner un collège!"; + v_msgEng="Please select a college!"; + alert_ebene(v_msg, v_msgEng); + + return; + } + + donnees = 'idBeneficiairemodel='+idBeneficiairemodel+'&idCollege='+idCollege; + + $.ajax({ + url: $("#racineWeb").val()+"Ajaximporterlisteassure/ajouterunadherentaucollege/", + type: 'POST', + data: donnees, + success: function(data) { + }, + error: function(data) { + }, + complete: function() { + afficher_adherent_importee(); + } + }); +} + + +function ajouter_tous_adherent_importe_college() +{ + idCollege=$("#idCollege").val(); + + if (idCollege<=" ") + { + v_msg="Veuillez sélectionner un collège!"; + v_msgEng="Please select a college!"; + alert_ebene(v_msg, v_msgEng); + + return; + } + + donnees = 'idCollege='+idCollege; + + v_msg="Attention, cela va vider tous les autres collèges! Confirmez-vous?"; + v_msgEng="Be careful, this will empty all other colleges! Do you confirm?"; + + if(confirm_ebene(v_msg, v_msgEng)) + { + $.ajax({ + url: $("#racineWeb").val()+"Ajaximporterlisteassure/ajoutertousadherentaucollege/", + type: 'POST', + data: donnees, + success: function(data) { + }, + error: function(data) { + }, + complete: function() { + afficher_adherent_importee(); + } + }); + } +} + +function ajouter_sans_college_adherent_importe_college() +{ + idCollege=$("#idCollege").val(); + + if (idCollege<=" ") + { + v_msg="Veuillez sélectionner un collège!"; + v_msgEng="Please select a college!"; + alert_ebene(v_msg, v_msgEng); + + return; + } + + donnees = 'idCollege='+idCollege; + + 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(); + } + }); + } +} + + +function retirer_tous_adherent_importe_college() +{ + idCollege=$("#idCollege").val(); + + if (idCollege<=" ") + { + v_msg="Veuillez sélectionner un collège!"; + v_msgEng="Please select a college!"; + alert_ebene(v_msg, v_msgEng); + + return; + } + + donnees = 'idCollege='+idCollege; + + 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(); + } + }); + } +} diff --git a/Vue/gabarit.php b/Vue/gabarit.php index c7d723e..bf72f77 100755 --- a/Vue/gabarit.php +++ b/Vue/gabarit.php @@ -635,7 +635,7 @@ $photoAssureCrypte = $_SESSION['photoAssureCrypte']; - +