86 lines
4.5 KiB
PHP
86 lines
4.5 KiB
PHP
<?php
|
|
$adminProd = $_SESSION['adminProd'];
|
|
?>
|
|
|
|
<?php if(count($actes) > 0): ?>
|
|
<div class="table-responsive shadow-sm rounded">
|
|
<table class="table table-sm table-hover table-bordered align-middle mb-0 text-nowrap">
|
|
<thead class="table-light border-bottom">
|
|
<tr class="text-center text-uppercase small fw-bold text-muted">
|
|
<th class="py-3 border-end text-center" style="width: 80px;"><?= _("Détail") ?></th>
|
|
<th class="border-end text-center"><?= _("Lettre") ?></th>
|
|
<th class="text-start ps-3 border-end text-center"><?= _("Désignation") ?></th>
|
|
<th class="border-end text-center"><?= _("Effet") ?></th>
|
|
<th class="border-end text-center"><?= _("Plafond") ?></th>
|
|
<th class="border-end text-center"><?= _("TM (%)") ?></th>
|
|
<th class="border-end text-center"><?= _("Nb Actes") ?></th>
|
|
<th class="text-center"><?= _("Statut") ?></th>
|
|
<th class="bg-white border-start text-center"><?= _("Actions") ?></th>
|
|
</tr>
|
|
</thead>
|
|
|
|
<tbody>
|
|
<?php foreach ($actes as $v):
|
|
$idActe = $this->nettoyer($v['id']);
|
|
$supprime = $v['supprime'];
|
|
$lettreCle = $this->nettoyer($v['lettreCle']);
|
|
$libelle = est_anglophone() ? $this->nettoyer($v['descriptionEng']) : $this->nettoyer($v['description']);
|
|
$isActif = ($this->nettoyer($v['actif']) == "1");
|
|
?>
|
|
|
|
<tr class="text-center <?= ($supprime == '1') ? 'table-danger opacity-50' : ''; ?>">
|
|
<td class="border-end p-2">
|
|
<button type="button" class="btn btn-info btn-xs fw-bold px-2 py-1 shadow-sm"
|
|
style="font-size: 0.75rem;"
|
|
onClick="javascript:detail_baremeacte_lettre_cle(<?= $idActe ?>, '<?= $lettreCle?>');">
|
|
<i class="fas fa-search-plus me-0"></i><?= _("Voir") ?>
|
|
</button>
|
|
</td>
|
|
|
|
<td class="fw-bold border-end"><?= $lettreCle ?></td>
|
|
<td class="text-start ps-3 border-end text-truncate" style="max-width: 250px;"><?= $libelle ?></td>
|
|
<td class="text-nowrap border-end"><?= dateLang($this->nettoyer($v['dateEffet']), $_SESSION['lang']); ?></td>
|
|
<td class="fw-bold text-primary border-end"><?= format_N($this->nettoyer($v['forfaitPlafond']));?></td>
|
|
<td class="text-danger border-end fw-bold"><?= intval($this->nettoyer($v['ticketModerateur']));?>%</td>
|
|
<td class="border-end"><?= format_N($this->nettoyer($v['nbActes']));?></td>
|
|
|
|
<td>
|
|
<span class="badge rounded-pill <?= $isActif ? 'bg-success' : 'bg-secondary' ?> px-2" style="font-size: 0.7rem;">
|
|
<?= $isActif ? _("Actif") : _("Inactif") ?>
|
|
</span>
|
|
</td>
|
|
|
|
<td class="bg-white border-start px-2">
|
|
<?php if($supprime == '0'): ?>
|
|
<button type="button" class="btn btn-sm btn-outline-danger border-0"
|
|
onClick="javascript:supprimer_baremeacte_lettre_cle('<?= $adminProd?>', <?= $idActe ?>);"
|
|
title="<?= _("Supprimer") ?>">
|
|
<i class="fas fa-trash-alt"></i>
|
|
</button>
|
|
<?php else: ?>
|
|
<span class="text-muted small italic"><?= _("Supprimé") ?></span>
|
|
<?php endif; ?>
|
|
</td>
|
|
</tr>
|
|
<?php endforeach; ?>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<?php else: ?>
|
|
<div class="alert alert-warning border-dashed text-center p-2 text-uppercase">
|
|
<i class="fas fa-info-circle fa-2x mb-2 d-block opacity-50"></i>
|
|
<?= _("Aucune lettre clé paramétrée pour ce barème.") ?>
|
|
</div>
|
|
<?php endif; ?>
|
|
|
|
<div class="modal fade" id="div_detail_bareme_actes" tabindex="-1" role="dialog" data-bs-backdrop="static" data-bs-keyboard="false" aria-hidden="true">
|
|
</div>
|
|
|
|
<style>
|
|
.btn-xs { padding: 0.125rem 0.25rem; font-size: 0.75rem; border-radius: 0.15rem; }
|
|
.table-hover tbody tr:hover { background-color: rgba(13, 110, 253, 0.05) !important; }
|
|
.opacity-50 { text-decoration: line-through rgba(220, 53, 69, 0.4); }
|
|
.border-dashed { border: 2px dashed #dee2e6 !important; background: transparent; }
|
|
.text-truncate { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
|
|
</style>
|