76 lines
3.9 KiB
PHP
76 lines
3.9 KiB
PHP
<?php $nbligne = 0; ?>
|
|
|
|
<div id="div_detail_requete" class="card border-0 shadow-sm animate__animated animate__fadeIn">
|
|
<div class="card-header bg-dark text-white p-3">
|
|
<div class="row align-items-center text-center">
|
|
<div class="col-md-4 border-end border-secondary">
|
|
<small class="text-uppercase opacity-75 d-block"><?= _("Volume Total") ?></small>
|
|
<span class="h5 fw-bold"><?= format_N($rpsinistres_total['nbLigne']) ?> <?= _("Lignes") ?></span>
|
|
</div>
|
|
<div class="col-md-4 border-end border-secondary">
|
|
<small class="text-uppercase opacity-75 d-block"><?= _("Cumul Sinistres") ?></small>
|
|
<span class="h5 fw-bold text-warning"><?= format_N($rpsinistres_total['sinistres_total']) ?></span>
|
|
</div>
|
|
<div class="col-md-4">
|
|
<i class="fas fa-info-circle me-1 text-info"></i>
|
|
<small><?= _("Affichage limité aux 200 premières lignes") ?></small>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="table-responsive">
|
|
<table class="table table-striped table-bordered table-hover table-condensed tabliste compact w-100" style="font-size:0.85rem; white-space:nowrap;">
|
|
<thead class="table-light border-bottom text-uppercase small fw-bold">
|
|
<tr>
|
|
<th class="text-center"><?= _("N° Adhérent") ?></th>
|
|
<th><?= _("Adhérent Principal") ?></th>
|
|
<th class="text-center"><?= _("Date de début") ?></th>
|
|
<th class="text-center"><?= _("Période passée") ?></th>
|
|
<th class="text-center"><?= _("Sinistres") ?></th>
|
|
<th class="text-center"><?= _("Ratio (%)") ?></th>
|
|
<th class="text-center">Cat</th>
|
|
</tr>
|
|
</thead>
|
|
|
|
<tbody>
|
|
<?php foreach ($rpsinistres as $rpsinistre):
|
|
$nbligne++;
|
|
$ratio = (float)$rpsinistre['ratio'];
|
|
// Couleur dynamique pour le ratio
|
|
$ratioClass = ($ratio > 100) ? 'text-danger fw-bold' : (($ratio > 70) ? 'text-warning' : 'text-success');
|
|
?>
|
|
<tr>
|
|
<td class="text-center fw-bold text-primary"><?= $this->nettoyer($rpsinistre['numeroAdherent']) ?></td>
|
|
<td><?= $this->nettoyer($rpsinistre['Adherent']) ?></td>
|
|
<td class="text-center text-muted"><?= dateLang($this->nettoyer($rpsinistre['dateEffetAdherent']), $_SESSION['lang']) ?></td>
|
|
<td class="text-center"><?= $this->nettoyer($rpsinistre['duree_acquise']) ?> <small><?= _("j") ?></small></td>
|
|
<td class="text-center fw-bold"><?= format_N($rpsinistre['sinistres']) ?></td>
|
|
|
|
<td class="text-center <?= $ratioClass ?>">
|
|
<?= number_format($ratio, 2, ',', ' ') ?> %
|
|
</td>
|
|
|
|
<td class="text-center">
|
|
<span class="badge bg-secondary-subtle text-secondary border border-secondary-subtle">
|
|
<?= $this->nettoyer($rpsinistre['codeProduit']) ?>
|
|
</span>
|
|
</td>
|
|
</tr>
|
|
|
|
<?php
|
|
if ($nbligne == 200) {
|
|
$nbligne = "> " . $nbligne . " => " . _("Utilisez l'export Excel");
|
|
break;
|
|
}
|
|
?>
|
|
<?php endforeach; ?>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="card-footer bg-white text-end py-2">
|
|
<small class="text-muted italic"><?= _("Généré le") ?> <?= date('d/m/Y H:i') ?></small>
|
|
</div>
|
|
|
|
<input class="sr-only" type="text" id="nbligne_info" name="nbligne_info" value="<?= $nbligne ?>">
|
|
</div>
|