This commit is contained in:
KONE SOREL 2026-04-07 17:55:00 +00:00
parent 6a95066720
commit decf034416
3 changed files with 55 additions and 31 deletions

View File

@ -62047,7 +62047,7 @@ function detail_baremepriseencharge(idBaremePriseEnCharge)
// 20-02-2022 // 20-02-2022
/** /**
* Gère l'affichage de la Section 1 : Standard de la Famille * Gère l'affichage de la Section 1 : Standard de la Garantie
*/ */
function afficherMasquerGarantiesBareme() { function afficherMasquerGarantiesBareme() {
debugger; debugger;
@ -62093,38 +62093,50 @@ function afficherMasquerGarantiesBareme() {
} }
function afficherMasquerGarantiesBaremeLienParente() /**
{ * Gère l'affichage de la Section 2 : Spécificités de la Garantie par Lien Parenté
*/
masquerGarantieLienParente = $("#masquerGarantieLienParente").val(); function afficherMasquerGarantiesBaremeLienParente() {
debugger;
// 1. Récupérer l'état actuel
var masquerGarantieLienParente = $("#masquerGarantieLienParente").val();
if (masquerGarantieLienParente == undefined) { masquerGarantieLienParente = "1"; }
// 2. Cibler les éléments
if(masquerGarantieLienParente == undefined){ var divMasquer = $('#div_garanties_lienparente_masquer');
masquerGarantieLienParente = "1"; var icone = $("#span_bareme");
}
if (masquerGarantieLienParente == "1") {
if(masquerGarantieLienParente=="1"){ // --- ACTION : FERMER ---
$('#div_garanties_lienparente_masquer').hide(); divMasquer.hide();
$("#masquerGarantieLienParente").val("0"); $("#masquerGarantieLienParente").val("0");
$("#span_garantie_lienparente").text("[+]");
// On remet le chevron vers le BAS (Fermé)
}else{ icone.attr('class', 'fas fa-chevron-down text-muted');
$('#div_garanties_lienparente_masquer').show();
$("#masquerGarantieLienParente").val("1"); } else {
intit_saisie_garantiebareme_lienparente(); // --- ACTION : OUVRIR ---
divMasquer.show();
$("#masquerGarantieLienParente").val("1");
intit_saisie_garantiebareme_lienparente();
actualiser_bareme_garantie_lienparente(); actualiser_bareme_garantie_lienparente();
$("#span_garantie_lienparente").text("[-]");
// On met le chevron vers le HAUT (Ouvert)
$("#masquerGarantie").val("1"); icone.attr('class', 'fas fa-chevron-up text-primary');
$("#masquerActe").val("1");
$("#masquerActeLienParente").val("1"); // --- ACCORDÉON : FERMER LES AUTRES ---
$("#masquerGarantieLienParente").val("1");
afficherMasquerGarantiesBareme(); $("#masquerActe").val("1");
$("#masquerActeLienParente").val("1");
afficherMasquerGarantiesBareme();
afficherMasquerActeBareme(); afficherMasquerActeBareme();
afficherMasquerActeBaremeLienParente(); afficherMasquerActeBaremeLienParente();
} }
afficheNombreLigneBareme('garantiesbaremepriseenchargelienparente'); // 3. Update compteur
afficheNombreLigneBareme('garantiesbaremepriseenchargelienparente');
} }

View File

@ -38,9 +38,12 @@
1. <?= _("Règle Standard de la Garantie") ?> 1. <?= _("Règle Standard de la Garantie") ?>
<span id="garantiesbaremepriseencharge" class="ms-2 badge bg-light text-primary border fs-6"></span> <span id="garantiesbaremepriseencharge" class="ms-2 badge bg-light text-primary border fs-6"></span>
</span> </span>
<i id="span_bareme" class="fas fa-chevron-down text-muted"></i> <i id="span_bareme" class="fas fa-chevron-down text-muted"></i>
</div> </div>
<input type="hidden" id="masquerGarantie" value="1"> <input type="hidden" id="masquerGarantie" value="1">
<div id="div_garanties_masquer" class="bg-light p-3 rounded shadow-sm border"> <div id="div_garanties_masquer" class="bg-light p-3 rounded shadow-sm border">
<h6 class="text-uppercase fw-bold text-secondary mb-3 small"> <h6 class="text-uppercase fw-bold text-secondary mb-3 small">
<i class="fas fa-layer-group me-2"></i><?= _("Particularités sur Garantie") ?> <i class="fas fa-layer-group me-2"></i><?= _("Particularités sur Garantie") ?>
@ -209,10 +212,16 @@
<div class="card border-0 shadow-sm mb-4 rounded-3"> <div class="card border-0 shadow-sm mb-4 rounded-3">
<div class="card-header bg-white py-3 cursor-pointer d-flex justify-content-between align-items-center" onclick="afficherMasquerGarantiesBaremeLienParente();"> <div class="card-header bg-white py-3 cursor-pointer d-flex justify-content-between align-items-center" onclick="afficherMasquerGarantiesBaremeLienParente();">
<span class="fw-bold text-dark small text-uppercase">2. <?= _("Spécificités de la Garantie par Profil (Lien Parenté)") ?> <span id="garantiesbaremepriseenchargelienparente" class="ms-2 badge bg-light text-primary border fw-normal"></span></span> <span class="fw-bold text-dark small text-uppercase">
2. <?= _("Spécificités de la Garantie par Lien Parenté") ?>
<span id="garantiesbaremepriseenchargelienparente" class="ms-2 badge bg-light text-primary border fs-6"></span>
</span>
<i id="span_garantie_lienparente" class="fas fa-chevron-down text-muted"></i> <i id="span_garantie_lienparente" class="fas fa-chevron-down text-muted"></i>
</div> </div>
<input type="hidden" id="masquerGarantieLienParente" value="1"> <input type="hidden" id="masquerGarantieLienParente" value="1">
<div id="div_garanties_lienparente_masquer" class="card-body border-top bg-white" style="display:none;"> <div id="div_garanties_lienparente_masquer" class="card-body border-top bg-white" style="display:none;">
<div class="p-4 mb-3 rounded-3 bg-light border-dashed"> <div class="p-4 mb-3 rounded-3 bg-light border-dashed">
<div class="row g-2 mb-3"> <div class="row g-2 mb-3">

View File

@ -1 +1,4 @@
<span id="garantiesbaremepriseenchargelienparente" ><?= "(".$nbgarantieLien.")"; ?></span> <?php
$txt_nbgarantieLien = ($nbgarantieLien < 10) ? "0".$nbgarantieLien : $nbgarantieLien;
?>
<span id="garantiesbaremepriseenchargelienparente" ><?= $txt_nbgarantieLien; ?></span>