This commit is contained in:
KONE SOREL 2026-04-13 15:06:38 +00:00
parent 6c1e655768
commit f1e1fa62c0

View File

@ -1,64 +1,42 @@
<?php $this->titre = "INTER SANTE - Tableau des taux d'ajustement de primes"; ?>
<div class="page-content animate__animated animate__fadeIn">
<div class="header-section mb-1">
<div class="d-flex align-items-center justify-content-between bg-white p-3 shadow-sm border-start border-primary border-4" style="border-radius: var(--radius-md);">
<div class="d-flex align-items-center">
<div class="icon-shape bg-primary-ghost text-primary rounded-circle me-3" style="width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;">
<i class="fas fa-percentage fs-4"></i>
</div>
<div>
<h4 id="titre-page" class="mb-0 fw-bold text-uppercase"><?= _("Taux d'ajustement de primes") ?></h4>
<p class="text-muted small mb-0"><?= _("Gestion de la grille des taux d'ajustement selon le rapport Sinistres/Primes (S/P)") ?></p>
</div>
</div>
<div class="d-flex gap-2">
<input class="sr-only" type="text" id="nomForm" name="nomForm" value="frmtauxAjustement">
</div>
</div>
</div>
<INPUT class="sr-only" TYPE="text" id="nomForm" name="nomForm" value="frmtauxAjustement">
<div id="div_entete_table" class="mb-2"></div>
<div id="div_maj_table" class="mb-3"></div>
<legend> <?= _("Grille des taux d'ajustement") ?> </legend>
<div id="div_entete_table">
<div id="div_lister_table">
<?php require "Vue/Ajaxtblistertauxajustement/index.php"; ?>
</div>
</div>
<div id="div_maj_table">
</div>
<style>
.bg-primary-ghost { background-color: rgba(13, 110, 253, 0.1); }
</style>
<div id="div_lister_table">
<?php
$nbreTotal = count($tableauajustement);
if($nbreTotal < 10){
$nbreTotal = '0'.$nbreTotal;
}else{
$nbreTotal = format_N($nbreTotal);
}
?>
<table style="margin: auto" class="table-responsive">
<tbody>
<td><input class="form-control" style="text-align: center; font-size:10pt;" type="text" id="nbreTotal" name="nbreTotal" value="<?= _("Lignes Total").": ". $nbreTotal; ?>" readonly> </td>
</tbody>
</table>
<input type="hidden" id="total" value="<?= $nbreTotal; ?>">
<table class="table table-striped table-bordered table-hover table-condensed table-responsive tabliste compact">
<thead>
<tr>
<th class="text-center"><?= _("Centre gestion")?></th>
<th class="text-center"><?= _("S/P Minimum")?></th>
<th class="text-center"><?= _("S/P Maximum")?></th>
<th class="text-center"><?= _("Taux")." (%)"?></th>
<th class="text-center"><?= _("Modifier")?></th>
</tr>
</thead>
<tbody>
<?php foreach ($tableauajustement as $v):
$idData = $this->nettoyer($v['id']);
?>
<tr valign="top">
<td class="text-center" width="15%"><?= $this->nettoyer($v['codeSociete']);; ?>
<td class="text-center" width="20%"><?= $this->nettoyer($v['spMin']) ?></td>
<td class="text-center" width="20%"><?= $this->nettoyer($v['spMax']) ?></td>
<td class="text-center" width="20%"><?= $this->nettoyer($v['tauxAjustement']) ?></td>
<td class="text-center" width="10%">
<button style="width:100%" class ="form-control btn btn-primary" type="button" id="btn-editer" name="Modifier"
onclick="JAVASCRIPT:formModifTableRef(<?= $idData; ?>);" ><?= _("Modifier") ?></button>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<script>
$(document).ready(function() {
/**
* Initialisation initiale du tableau
* On utilise initDataTableReference avec un tri par S/P Minimum (colonne index 1)
*/
if (typeof initDataTableReference === 'function') {
const titreExport = "<?= _('Grille des taux ajustement') ?>";
initDataTableReference('#tableLister', titreExport, [[1, 'asc']]);
}
});
</script>