fe
This commit is contained in:
parent
4caf707c9e
commit
ef733ccff7
|
|
@ -72,81 +72,37 @@ class ControleurAjaxhabilitation extends Controleur
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public function ajoutertoussousmenusass()
|
public function ajoutertoussousmenusrh()
|
||||||
{
|
{
|
||||||
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
||||||
$vue = $this->requete->getParametreFormulaire("vue");
|
$codeVue = $this->requete->getParametreFormulaire("codeVue");
|
||||||
|
|
||||||
$this->utilisateur->ajoutertoussousmenusass($codeProfil, $vue);
|
$this->utilisateur->ajoutertoussousmenusrh($codeProfil, $codeVue);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function retirertoussousmenusass()
|
public function retirertoussousmenusrh()
|
||||||
{
|
{
|
||||||
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
||||||
$vue = $this->requete->getParametreFormulaire("vue");
|
$codeVue = $this->requete->getParametreFormulaire("codeVue");
|
||||||
|
|
||||||
$this->utilisateur->retirertoussousmenusass($codeProfil, $vue);
|
$this->utilisateur->retirertoussousmenusrh($codeProfil, $codeVue);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function ajouterunsousmenusass()
|
public function ajouterunsousmenurh()
|
||||||
{
|
{
|
||||||
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
||||||
$vue = $this->requete->getParametreFormulaire("vue");
|
$codeVue = $this->requete->getParametreFormulaire("codeVue");
|
||||||
$codeMenu = $this->requete->getParametreFormulaire("codeMenu");
|
$codeMenu = $this->requete->getParametreFormulaire("codeMenu");
|
||||||
|
|
||||||
$this->utilisateur->ajouterunsousmenusass($codeProfil, $vue, $codeMenu);
|
$this->utilisateur->ajouterunsousmenurh($codeProfil, $codeVue, $codeMenu);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function retirerunsousmenusass()
|
public function retirerunsousmenurh()
|
||||||
{
|
{
|
||||||
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
||||||
$vue = $this->requete->getParametreFormulaire("vue");
|
$codeVue = $this->requete->getParametreFormulaire("codeVue");
|
||||||
$codeMenu = $this->requete->getParametreFormulaire("codeMenu");
|
$codeMenu = $this->requete->getParametreFormulaire("codeMenu");
|
||||||
|
|
||||||
$this->utilisateur->retirerunsousmenusass($codeProfil, $vue, $codeMenu);
|
$this->utilisateur->retirerunsousmenurh($codeProfil, $codeVue, $codeMenu);
|
||||||
}
|
|
||||||
|
|
||||||
public function creerprofilass()
|
|
||||||
{
|
|
||||||
$libelle = $this->requete->getParametreFormulaire("libelle");
|
|
||||||
$libelleEng = $this->requete->getParametreFormulaire("libelleEng");
|
|
||||||
|
|
||||||
$this->utilisateur->creerprofilass($libelle, $libelleEng);
|
|
||||||
}
|
|
||||||
|
|
||||||
public function transfererdroitsprofilassureur()
|
|
||||||
{
|
|
||||||
$codeProfilSource = $this->requete->getParametreFormulaire("codeProfilSource");
|
|
||||||
$codeProfilDest = $this->requete->getParametreFormulaire("codeProfilDest");
|
|
||||||
|
|
||||||
$this->utilisateur->transfererdroitsprofilassureur($codeProfilSource, $codeProfilDest);
|
|
||||||
|
|
||||||
// $this->genererVueAjax();
|
|
||||||
}
|
|
||||||
|
|
||||||
public function batchviderprofilass()
|
|
||||||
{
|
|
||||||
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
|
||||||
|
|
||||||
$this->utilisateur->batchviderprofilass($codeProfil);
|
|
||||||
}
|
|
||||||
|
|
||||||
public function batchattribuerdroitsreferenceass()
|
|
||||||
{
|
|
||||||
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
|
||||||
|
|
||||||
$this->utilisateur->batchattribuerdroitsreferenceass($codeProfil);
|
|
||||||
}
|
|
||||||
|
|
||||||
public function ajaxlisteusersass()
|
|
||||||
{
|
|
||||||
$codeProfil = $this->requete->getParametreFormulaire("codeProfil");
|
|
||||||
$nom = $this->requete->getParametreFormulaire("nom");
|
|
||||||
$prenoms = $this->requete->getParametreFormulaire("prenoms");
|
|
||||||
$codePointVente = $this->requete->getParametreFormulaire("codePointVente");
|
|
||||||
|
|
||||||
$users = $this->utilisateur->getusersassueurfiltre($codeProfil, $nom, $prenoms, $codePointVente);
|
|
||||||
|
|
||||||
$this->genererVueAjax(array('users' => $users));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
176
Js/fonctions.js
176
Js/fonctions.js
|
|
@ -4999,8 +4999,6 @@ function ajax_menus_profil()
|
||||||
|
|
||||||
function afficher_menu_vue_profil()
|
function afficher_menu_vue_profil()
|
||||||
{
|
{
|
||||||
debugger;
|
|
||||||
|
|
||||||
codeProfil=$("#codeProfil").val();
|
codeProfil=$("#codeProfil").val();
|
||||||
if (codeProfil<=" ")
|
if (codeProfil<=" ")
|
||||||
{
|
{
|
||||||
|
|
@ -5055,4 +5053,178 @@ function afficher_menu_vue_profil()
|
||||||
complete: function() {
|
complete: function() {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function ajouter_tous_menu_vue_profil()
|
||||||
|
{
|
||||||
|
codeProfil=$("#codeProfil").val();
|
||||||
|
|
||||||
|
if (codeProfil<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner un profil!";
|
||||||
|
v_msgEng="Please select a user profile!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeProfil").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
codeVue=$("#codeVue").val();
|
||||||
|
|
||||||
|
if (codeVue<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner une vue!";
|
||||||
|
v_msgEng="Please select a view!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeVue").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
donnees = 'codeProfil='+codeProfil;
|
||||||
|
donnees += '&codeVue='+codeVue;
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: $("#racineWeb").val()+"Ajaxhabilitation/ajoutertoussousmenusrh/",
|
||||||
|
type: 'POST',
|
||||||
|
data: donnees,
|
||||||
|
success: function(data) {
|
||||||
|
},
|
||||||
|
error: function(data) {
|
||||||
|
},
|
||||||
|
complete: function() {
|
||||||
|
afficher_menu_vue_profil();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function ajouter_un_menu_vue_profil(codeMenu)
|
||||||
|
{
|
||||||
|
codeProfil=$("#codeProfil").val();
|
||||||
|
|
||||||
|
if (codeProfil<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner un profil!";
|
||||||
|
v_msgEng="Please select a user profile!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeProfil").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
codeVue=$("#codeVue").val();
|
||||||
|
|
||||||
|
if (codeVue<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner une vue!";
|
||||||
|
v_msgEng="Please select a view!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeVue").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
donnees = 'codeProfil='+codeProfil;
|
||||||
|
donnees += '&vue='+vue;
|
||||||
|
donnees += '&codeMenu='+codeMenu;
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: $("#racineWeb").val()+"Ajaxhabilitation/ajouterunsousmenurh/",
|
||||||
|
type: 'POST',
|
||||||
|
data: donnees,
|
||||||
|
success: function(data) {
|
||||||
|
},
|
||||||
|
error: function(data) {
|
||||||
|
},
|
||||||
|
complete: function() {
|
||||||
|
afficher_menu_vue_profil();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function retirer_tous_menu_vue_profil()
|
||||||
|
{
|
||||||
|
codeProfil=$("#codeProfil").val();
|
||||||
|
|
||||||
|
if (codeProfil<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner un profil!";
|
||||||
|
v_msgEng="Please select a user profile!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeProfil").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
codeVue=$("#codeVue").val();
|
||||||
|
|
||||||
|
if (codeVue<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner une vue!";
|
||||||
|
v_msgEng="Please select a view!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeVue").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
donnees = 'codeProfil='+codeProfil;
|
||||||
|
donnees += '&codeVue='+codeVue;
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: $("#racineWeb").val()+"Ajaxhabilitation/retirertoussousmenusrh/",
|
||||||
|
type: 'POST',
|
||||||
|
data: donnees,
|
||||||
|
success: function(data) {
|
||||||
|
},
|
||||||
|
error: function(data) {
|
||||||
|
},
|
||||||
|
complete: function() {
|
||||||
|
afficher_menu_vue_profil();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function retirer_un_menu_vue_profil(codeMenu)
|
||||||
|
{
|
||||||
|
codeProfil=$("#codeProfil").val();
|
||||||
|
|
||||||
|
if (codeProfil<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner un profil!";
|
||||||
|
v_msgEng="Please select a user profile!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeProfil").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
codeVue=$("#codeVue").val();
|
||||||
|
|
||||||
|
if (codeVue<=" ")
|
||||||
|
{
|
||||||
|
v_msg="Veuillez sélectionner une vue!";
|
||||||
|
v_msgEng="Please select a view!";
|
||||||
|
alert_ebene(v_msg, v_msgEng);
|
||||||
|
|
||||||
|
$("#codeVue").focus();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
donnees = 'codeProfil='+codeProfil;
|
||||||
|
donnees += '&codeVue='+codeVue;
|
||||||
|
donnees += '&codeMenu='+codeMenu;
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
url: $("#racineWeb").val()+"Ajaxhabilitation/retirerunsousmenurh/",
|
||||||
|
type: 'POST',
|
||||||
|
data: donnees,
|
||||||
|
success: function(data) {
|
||||||
|
},
|
||||||
|
error: function(data) {
|
||||||
|
},
|
||||||
|
complete: function() {
|
||||||
|
afficher_menu_vue_profil();
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
@ -271,4 +271,43 @@ class Utilisateur extends Modele {
|
||||||
return $menu->fetchAll(PDO::FETCH_ASSOC);
|
return $menu->fetchAll(PDO::FETCH_ASSOC);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function ajoutertoussousmenusrh($codeProfil, $codeVue)
|
||||||
|
{
|
||||||
|
$codeSociete = $_SESSION['codeSociete'];
|
||||||
|
$user = $_SESSION['login'];
|
||||||
|
|
||||||
|
$sql = 'call sp_c_ajouter_tous_sous_menus_profil_rh(?, ?, ?, ?)';
|
||||||
|
|
||||||
|
$this->executerRequete($sql, array($codeSociete, $codeProfil, $codeVue, $user));
|
||||||
|
}
|
||||||
|
|
||||||
|
public function ajouterunsousmenurh($codeProfil, $codeVue, $codeMenu)
|
||||||
|
{
|
||||||
|
$codeSociete = $_SESSION['codeSociete'];
|
||||||
|
$user = $_SESSION['login'];
|
||||||
|
|
||||||
|
$sql = 'call sp_c_ajouter_un_sous_menus_profil_rh(?, ?, ?, ?, ?)';
|
||||||
|
|
||||||
|
$this->executerRequete($sql, array($codeSociete, $codeProfil, $codeVue, $codeMenu, $user));
|
||||||
|
}
|
||||||
|
|
||||||
|
public function retirertoussousmenusrh($codeProfil, $codeVue)
|
||||||
|
{
|
||||||
|
$codeSociete = $_SESSION['codeSociete'];
|
||||||
|
$user = $_SESSION['login'];
|
||||||
|
|
||||||
|
$sql = 'call sp_c_retirer_tous_sous_menus_profil_rh(?, ?, ?, ?)';
|
||||||
|
|
||||||
|
$this->executerRequete($sql, array($codeSociete, $codeProfil, $vue, $user));
|
||||||
|
}
|
||||||
|
|
||||||
|
public function retirerunsousmenurh($codeProfil, $codeVue, $codeMenu)
|
||||||
|
{
|
||||||
|
$codeSociete = $_SESSION['codeSociete'];
|
||||||
|
$user = $_SESSION['login'];
|
||||||
|
|
||||||
|
$sql = 'call sp_c_retirer_un_sous_menus_profil_rh(?, ?, ?, ?, ?)';
|
||||||
|
|
||||||
|
$this->executerRequete($sql, array($codeSociete, $codeProfil, $vue, $codeMenu, $user));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -12,7 +12,7 @@
|
||||||
|
|
||||||
<div class="px-3 pb-2">
|
<div class="px-3 pb-2">
|
||||||
<button type="button" class="btn btn-sm btn-info text-white w-100 fw-bold shadow-xs transition-btn"
|
<button type="button" class="btn btn-sm btn-info text-white w-100 fw-bold shadow-xs transition-btn"
|
||||||
onclick="javascript:ajouter_tous_menu_vue_module_assureur();">
|
onclick="javascript:ajouter_tous_menu_vue_profil();">
|
||||||
<?= _("Tout ajouter") ?> <i class="fas fa-chevron-right ms-1"></i>
|
<?= _("Tout ajouter") ?> <i class="fas fa-chevron-right ms-1"></i>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -29,7 +29,7 @@
|
||||||
<td class="text-end pe-3" width="60">
|
<td class="text-end pe-3" width="60">
|
||||||
<button class="btn btn-sm btn-outline-info rounded-circle btn-action"
|
<button class="btn btn-sm btn-outline-info rounded-circle btn-action"
|
||||||
title="<?= _("Ajouter") ?>"
|
title="<?= _("Ajouter") ?>"
|
||||||
onClick="javascript:ajouter_un_menu_vue_module_assureur('<?=$codeMenu?>');">
|
onClick="javascript:ajouter_un_menu_vue_profil('<?=$codeMenu?>');">
|
||||||
<i class="fas fa-plus"></i>
|
<i class="fas fa-plus"></i>
|
||||||
</button>
|
</button>
|
||||||
</td>
|
</td>
|
||||||
|
|
@ -52,7 +52,7 @@
|
||||||
|
|
||||||
<div class="px-3 pb-2">
|
<div class="px-3 pb-2">
|
||||||
<button type="button" class="btn btn-sm btn-outline-secondary w-100 fw-bold shadow-xs transition-btn"
|
<button type="button" class="btn btn-sm btn-outline-secondary w-100 fw-bold shadow-xs transition-btn"
|
||||||
onclick="javascript:retirer_tous_menu_vue_module_assureur();">
|
onclick="javascript:retirer_tous_menu_vue_profil();">
|
||||||
<i class="fas fa-chevron-left me-1"></i> <?= _("Tout retirer") ?>
|
<i class="fas fa-chevron-left me-1"></i> <?= _("Tout retirer") ?>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -68,7 +68,7 @@
|
||||||
<td class="ps-3" width="60">
|
<td class="ps-3" width="60">
|
||||||
<button class="btn btn-sm btn-outline-secondary rounded-circle btn-action"
|
<button class="btn btn-sm btn-outline-secondary rounded-circle btn-action"
|
||||||
title="<?= _("Retirer") ?>"
|
title="<?= _("Retirer") ?>"
|
||||||
onClick="javascript:retirer_un_menu_vue_module_assureur('<?=$codeMenu?>');">
|
onClick="javascript:retirer_un_menu_vue_profil('<?=$codeMenu?>');">
|
||||||
<i class="fas fa-minus"></i>
|
<i class="fas fa-minus"></i>
|
||||||
</button>
|
</button>
|
||||||
</td>
|
</td>
|
||||||
|
|
|
||||||
|
|
@ -662,7 +662,7 @@ $photoAssureCrypte = $_SESSION['photoAssureCrypte'];
|
||||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||||
|
|
||||||
<!-- Application Scripts -->
|
<!-- Application Scripts -->
|
||||||
<script src="/Js/fonctions.js?ver=2026.01.16.05"></script>
|
<script src="/Js/fonctions.js?ver=2026.01.16.06"></script>
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
raffraichier_gabarit();
|
raffraichier_gabarit();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user