135 lines
7.8 KiB
PHP
135 lines
7.8 KiB
PHP
<div class="table-responsive shadow-sm rounded border animate__animated animate__fadeIn">
|
|
<table class="table table-hover align-middle mb-0 tabliste compact w-100" style="font-size: 0.85rem;">
|
|
<thead class="table-light text-secondary text-uppercase small">
|
|
<tr>
|
|
<th class="text-center border-0 py-3"><?= _("Date Effet") ?></th>
|
|
<th class="text-center border-0"><?= _("Mvt") ?></th>
|
|
<th class="border-0"><?= _("Bénéficiaire / Matricule") ?></th>
|
|
<th class="border-0"><?= _("Adhérent") ?></th>
|
|
<th class="text-center border-0"><?= _("Lien") ?></th>
|
|
<th class="text-center border-0"><?= _("Saisie / Par") ?></th>
|
|
<th class="text-center border-0"><?= _("Statut") ?></th>
|
|
<th class="text-center border-0"><?= _("Validation") ?></th>
|
|
<th class="text-center border-0"><?= _("Saisie Client") ?></th>
|
|
</tr>
|
|
</thead>
|
|
|
|
<tbody>
|
|
<?php foreach ($mouvementassures as $mvt):
|
|
$idMvt = $this->nettoyer($mvt['ajoutClient']);
|
|
$ajoutClient = $this->nettoyer($mvt['ajoutClient']);
|
|
$valide = $this->nettoyer($mvt['valide']);
|
|
$rejet = $this->nettoyer($mvt['rejet']);
|
|
$motif = $this->nettoyer($mvt['motif']);
|
|
$aCorriger = $this->nettoyer($mvt['aCorriger']);
|
|
$sensMvt = $mvt['sensMouvement'];
|
|
|
|
$libelleSensMouvement = est_anglophone() ? $mvt['libelleSensMouvementEng'] : $mvt['libelleSensMouvement'];
|
|
$idBeneficiaire = $this->nettoyer($mvt['idBeneficiaire']);
|
|
$idAvenant = $this->nettoyer($mvt['idAvenant']);
|
|
?>
|
|
<tr>
|
|
<td class="text-center fw-bold text-dark">
|
|
<?= dateLang($this->nettoyer($mvt['dateEffet']), $_SESSION['lang']) ?>
|
|
</td>
|
|
|
|
<td class="text-center">
|
|
<?php if ($sensMvt == '1'): // Entrée ?>
|
|
<span class="badge rounded-pill bg-success-subtle text-success border border-success-subtle px-3">
|
|
<i class="fas fa-sign-in-alt me-1"></i> <?= $libelleSensMouvement ?>
|
|
</span>
|
|
<?php else: // Sortie ?>
|
|
<span class="badge rounded-pill bg-danger-subtle text-danger border border-danger-subtle px-3">
|
|
<i class="fas fa-sign-out-alt me-1"></i> <?= $libelleSensMouvement ?>
|
|
</span>
|
|
<?php endif; ?>
|
|
</td>
|
|
|
|
<td>
|
|
<div class="fw-bold text-uppercase text-secondary"><?= $this->nettoyer($mvt['beneficiaire']) ?></div>
|
|
<div class="text-muted x-small"><i class="fas fa-id-card me-1"></i><?= $this->nettoyer($mvt['numeroBeneficiaire']) ?></div>
|
|
</td>
|
|
|
|
<td class="small">
|
|
<i class="fas fa-user-tie text-secondary me-1"></i> <?= $this->nettoyer($mvt['adherent']) ?>
|
|
</td>
|
|
|
|
<td class="text-center">
|
|
<span class="badge bg-light text-secondary border"><?= $this->nettoyer($mvt['codeLienParente']) ?></span>
|
|
</td>
|
|
|
|
<td class="text-center">
|
|
<div class="small fw-bold"><?= $this->nettoyer($mvt['codeUtilisateur']) ?></div>
|
|
<div class="x-small text-muted italic"><?= dateheureLang($this->nettoyer($mvt['dateSysteme']), $_SESSION['lang']) ?></div>
|
|
</td>
|
|
|
|
<td class="text-center">
|
|
<?php if ($valide == "1"): ?>
|
|
<?php if ($rejet == "0"): ?>
|
|
<span class="text-success fw-bold small mb-1 italic">
|
|
<i class="fas fa-check-circle"></i> <?= _('Validé') ?>
|
|
</span>
|
|
<?php elseif ($aCorriger == "1"): ?>
|
|
<div class="d-flex flex-column align-items-center">
|
|
<span class="text-info fw-bold small mb-1 italic"><i class="fas fa-exclamation-triangle"></i> <?= _('A Corriger') ?></span>
|
|
<button class="btn btn-xs btn-outline-info py-0 px-2" onclick="motif_rejet('<?= $motif; ?>');">
|
|
<i class="fas fa-eye"></i> <?= _("Motif") ?>
|
|
</button>
|
|
</div>
|
|
<?php else: ?>
|
|
<div class="d-flex flex-column align-items-center">
|
|
<span class="text-danger fw-bold small mb-1 italic"><i class="fas fa-times-circle"></i> <?= _('Rejeté') ?></span>
|
|
<button class="btn btn-xs btn-outline-danger py-0 px-2" onclick="motif_rejet('<?= $motif; ?>');">
|
|
<i class="fas fa-eye"></i> <?= _("Motif") ?>
|
|
</button>
|
|
</div>
|
|
<?php endif; ?>
|
|
<?php else: ?>
|
|
<span class="text-muted opacity-50 small mb-1 italic">
|
|
<i class="fas fa-clock fa-lg"></i> <?= _('En attente') ?>
|
|
</span>
|
|
<?php endif; ?>
|
|
</td>
|
|
|
|
<td class="text-center">
|
|
<?php if ($valide == "1"): ?>
|
|
<?php if ($aCorriger == "0"): ?>
|
|
<div class="small fw-bold text-dark"><?= $this->nettoyer($mvt['userValidation']) ?></div>
|
|
<div class="x-small text-muted"><?= dateheureLang($this->nettoyer($mvt['dateValidation']), $_SESSION['lang']) ?></div>
|
|
<?php else: ?>
|
|
<button class="btn btn-xs btn-info fw-bold shadow-sm rounded-pill px-3 transition-hover text-white"
|
|
onclick="corriger_mvt_beneficiaire(<?= $idBeneficiaire; ?>, <?= $idAvenant; ?>);">
|
|
<i class="fas fa-tools me-1"></i> <?= _("Corriger") ?>
|
|
</button>
|
|
<?php endif; ?>
|
|
<?php else: ?>
|
|
<button class="btn btn-xs btn-warning fw-bold shadow-sm rounded-pill px-3 transition-hover text-white"
|
|
onclick="modifier_beneficiaire('<?= $idBeneficiaire; ?>');">
|
|
<i class="fas fa-edit me-1"></i> <?= _("Modifier") ?>
|
|
</button>
|
|
<?php endif; ?>
|
|
</td>
|
|
|
|
<td class="text-center">
|
|
<?php if ($ajoutClient == "1"): ?>
|
|
<span class="badge bg-primary-subtle text-primary border border-primary-subtle"><?= _("Oui") ?></span>
|
|
<?php else: ?>
|
|
<span class="badge bg-light text-muted border"><?= _("Non") ?></span>
|
|
<?php endif; ?>
|
|
</td>
|
|
</tr>
|
|
<?php endforeach; ?>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<style>
|
|
.x-small { font-size: 0.7rem; }
|
|
.italic { font-style: italic; }
|
|
.bg-success-subtle { background-color: #d1e7dd !important; }
|
|
.bg-danger-subtle { background-color: #f8d7da !important; }
|
|
.bg-primary-subtle { background-color: #cfe2ff !important; }
|
|
.btn-xs { padding: 0.1rem 0.3rem; font-size: 0.7rem; line-height: 1.5; border-radius: 0.2rem; }
|
|
.transition-hover { transition: all 0.2s ease-in-out; }
|
|
.transition-hover:hover { transform: translateY(-2px); box-shadow: 0 4px 8px rgba(0,0,0,0.1) !important; }
|
|
</style>
|