a
This commit is contained in:
parent
847ff50997
commit
e266200ac9
|
|
@ -1,727 +0,0 @@
|
|||
<?php
|
||||
$this->titre = "Intersanté - Accueil";
|
||||
|
||||
$pourcentage = round((100*$limite_adherent['consommation'])/$limite_adherent['plafond']);
|
||||
?>
|
||||
<input type="text" id="nomForm" name="nomForm" class="sr-only" value="frmaccueil">
|
||||
<div class="col-12">
|
||||
<!-- Header -->
|
||||
<header class="mb-4">
|
||||
<h1 class="text-3xl font-bold text-center">
|
||||
<?= _('Famille ').$_SESSION['adherent_C'].' ('.$_SESSION['numeroAdherent_C'].")"; ?>
|
||||
</h1>
|
||||
</header>
|
||||
|
||||
|
||||
<!-- Cards Section -->
|
||||
<div class="row">
|
||||
<!-- Taux de couverture -->
|
||||
<div class="col-xl-3 col-md-6 mb-4">
|
||||
<div class="card border-left-warning shadow h-100">
|
||||
<div class="card-body p-3">
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="flex-grow-1">
|
||||
<div class="small font-weight-bold text-warning text-uppercase mb-1">
|
||||
<?= _("Couverture")?>
|
||||
</div>
|
||||
<div class="h5 mb-0 font-weight-bold text-gray-800">
|
||||
<?=$this->nettoyer(100-$adherent['ticketModerateurAdherent'])?>%
|
||||
</div>
|
||||
</div>
|
||||
<div class="ml-2">
|
||||
<i class="fas fa-percentage fa-2x text-gray-300"></i>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Plafond annuel -->
|
||||
<div class="col-xl-3 col-md-6 mb-4">
|
||||
<div class="card border-left-primary shadow h-100">
|
||||
<div class="card-body p-3">
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="flex-grow-1">
|
||||
<div class="small font-weight-bold text-primary text-uppercase mb-1">
|
||||
<?= _("Plafond Annuel") ?>
|
||||
</div>
|
||||
<div class="h5 mb-0 font-weight-bold text-gray-800">
|
||||
<?= format_N($limite_adherent['plafond'])." ".$_SESSION['devise_C'] ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ml-2">
|
||||
<i class="fas fa-calendar fa-2x text-gray-300"></i>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Consommation Annuelle -->
|
||||
<div class="col-xl-3 col-md-6 mb-4">
|
||||
<div class="card border-left-info shadow h-100">
|
||||
<div class="card-body p-3">
|
||||
<div class="d-flex flex-column">
|
||||
<div class="small font-weight-bold text-info text-uppercase mb-1">
|
||||
<?= _("Consommation Annuelle") ?>
|
||||
</div>
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="h5 mb-0 font-weight-bold text-gray-800 mr-2">
|
||||
<?= format_N($limite_adherent['consommation'])." ".$_SESSION['devise_C'] ?>
|
||||
</div>
|
||||
<div class="progress flex-grow-1" style="height: 6px;">
|
||||
<div class="progress-bar bg-info" role="progressbar"
|
||||
style="width: <?= $pourcentage; ?>%"
|
||||
aria-valuenow="<?= $pourcentage; ?>"
|
||||
aria-valuemin="0"
|
||||
aria-valuemax="100">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Solde Annuel -->
|
||||
<div class="col-xl-3 col-md-6 mb-4">
|
||||
<div class="card border-left-success shadow h-100">
|
||||
<div class="card-body p-3">
|
||||
<div class="d-flex align-items-center">
|
||||
<div class="flex-grow-1">
|
||||
<div class="small font-weight-bold text-success text-uppercase mb-1">
|
||||
<?= _("Solde Annuel") ?>
|
||||
</div>
|
||||
<div class="h5 mb-0 font-weight-bold text-gray-800">
|
||||
<?= format_N($limite_adherent['soldeConsommation'])." ".$_SESSION['devise_C'] ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ml-2">
|
||||
<i class="fas fa-money-bill-wave fa-2x text-gray-300"></i>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-12 tab-container">
|
||||
<!-- Enhanced Charts Section -->
|
||||
<div class="row">
|
||||
<!-- Responsive Area Chart -->
|
||||
<div class="col-xl-8 col-lg-7 mb-4">
|
||||
<div class="card shadow h-100">
|
||||
<div class="card-header py-3 d-flex flex-column flex-md-row justify-content-between align-items-center">
|
||||
<h6 class="m-0 font-weight-bold text-primary"><?= _("Dépenses mensuelles") ?></h6>
|
||||
<div class="mt-2 mt-md-0">
|
||||
<small class="text-muted"><?= _("Évolution sur 12 mois") ?></small>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="chart-container" style="position: relative; height:300px; width:100%">
|
||||
<canvas id="expenseTrendChart"></canvas>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Responsive Pie Chart -->
|
||||
<div class="col-xl-4 col-lg-5 mb-4">
|
||||
<div class="card shadow h-100">
|
||||
<div class="card-header py-3">
|
||||
<h6 class="m-0 font-weight-bold text-primary"><?= _("Dépenses par lien parenté") ?></h6>
|
||||
</div>
|
||||
<div class="card-body d-flex flex-column">
|
||||
<div class="chart-container" style="position: relative; height:250px; width:100%">
|
||||
<canvas id="expenseDistributionChart"></canvas>
|
||||
</div>
|
||||
|
||||
<!-- Conteneur pour la légende -->
|
||||
<div id="pieChartLegend" class="mt-3 text-center"></div>
|
||||
|
||||
<div class="mt-auto pt-3">
|
||||
<small class="text-muted"><?= _("Répartition en pourcentage") ?></small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/chartjs-plugin-datalabels@2.0.0"></script>
|
||||
|
||||
<script>
|
||||
// Récupération de la devise depuis PHP
|
||||
const userCurrency = '<?= isset($_SESSION['devise_C']) ? $_SESSION['devise_C'] : 'F CFA' ?>';
|
||||
|
||||
// Configuration des devises
|
||||
const currencyFormats = {
|
||||
'F CFA': {
|
||||
symbol: 'F CFA',
|
||||
format: (value) => new Intl.NumberFormat('fr-FR').format(value) + ' F CFA'
|
||||
},
|
||||
'€': {
|
||||
symbol: '€',
|
||||
format: (value) => new Intl.NumberFormat('fr-FR', {style: 'currency', currency: 'EUR'}).format(value)
|
||||
},
|
||||
'$': {
|
||||
symbol: '$',
|
||||
format: (value) => new Intl.NumberFormat('fr-FR', {style: 'currency', currency: 'USD'}).format(value)
|
||||
},
|
||||
'XOF': {
|
||||
symbol: 'F CFA',
|
||||
format: (value) => new Intl.NumberFormat('fr-FR').format(value) + ' F CFA'
|
||||
}
|
||||
};
|
||||
|
||||
// Format monétaire dynamique
|
||||
const formatMoney = (value) => {
|
||||
const currencyConfig = currencyFormats[userCurrency] || currencyFormats['F CFA'];
|
||||
return currencyConfig.format(value);
|
||||
};
|
||||
|
||||
// Format pourcentage
|
||||
const formatPercentage = (value, total) => {
|
||||
const percentage = (value * 100 / total).toFixed(1);
|
||||
return percentage + '%';
|
||||
};
|
||||
|
||||
// Détection mobile
|
||||
const isMobile = window.matchMedia("(max-width: 768px)").matches;
|
||||
|
||||
// Génération des couleurs
|
||||
const generateColors = (count) => {
|
||||
const palette = [
|
||||
'#4e73df', '#1cc88a', '#36b9cc', '#f6c23e',
|
||||
'#e74a3b', '#858796', '#5a5c69', '#3a3b45',
|
||||
'#2e59a9', '#17a673', '#2c9faf', '#dda20a'
|
||||
];
|
||||
return palette.slice(0, count).concat(
|
||||
Array.from({length: Math.max(0, count - palette.length)}, (_, i) => {
|
||||
const hue = Math.floor(360 * (i / Math.max(1, count - palette.length)));
|
||||
return `hsl(${hue}, 70%, 60%)`;
|
||||
})
|
||||
);
|
||||
};
|
||||
|
||||
// Graphique d'évolution des dépenses
|
||||
const trendCtx = document.getElementById('expenseTrendChart').getContext('2d');
|
||||
const trendChart = new Chart(trendCtx, {
|
||||
type: 'line',
|
||||
data: {
|
||||
labels: <?= $labels_mois; ?>,
|
||||
datasets: [{
|
||||
label: '<?= _("Montant dépensé") ?>',
|
||||
data: <?= $data_consos; ?>,
|
||||
backgroundColor: 'rgba(78, 115, 223, 0.05)',
|
||||
borderColor: 'rgba(78, 115, 223, 1)',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: 'rgba(78, 115, 223, 1)',
|
||||
pointRadius: isMobile ? 3 : 4,
|
||||
pointHoverRadius: 6,
|
||||
fill: true,
|
||||
tension: 0.3
|
||||
}]
|
||||
},
|
||||
options: {
|
||||
responsive: true,
|
||||
maintainAspectRatio: false,
|
||||
plugins: {
|
||||
legend: {
|
||||
display: false
|
||||
},
|
||||
tooltip: {
|
||||
mode: 'index',
|
||||
intersect: false,
|
||||
callbacks: {
|
||||
label: function(context) {
|
||||
return context.dataset.label + ': ' + formatMoney(context.parsed.y);
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
scales: {
|
||||
x: {
|
||||
grid: {
|
||||
display: false
|
||||
},
|
||||
ticks: {
|
||||
maxRotation: isMobile ? 45 : 0,
|
||||
autoSkip: true,
|
||||
maxTicksLimit: isMobile ? 6 : 12
|
||||
}
|
||||
},
|
||||
y: {
|
||||
beginAtZero: false,
|
||||
ticks: {
|
||||
callback: function(value) {
|
||||
return formatMoney(value);
|
||||
}
|
||||
},
|
||||
grid: {
|
||||
color: 'rgba(0, 0, 0, 0.05)'
|
||||
}
|
||||
}
|
||||
},
|
||||
interaction: {
|
||||
mode: 'nearest',
|
||||
axis: 'x',
|
||||
intersect: false
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
// Graphique de répartition
|
||||
const distributionCtx = document.getElementById('expenseDistributionChart').getContext('2d');
|
||||
const distributionChart = new Chart(distributionCtx, {
|
||||
type: 'pie',
|
||||
data: {
|
||||
labels: <?= $labels_liens; ?>,
|
||||
datasets: [{
|
||||
data: <?= $data_liens; ?>,
|
||||
backgroundColor: generateColors(<?= $nbreLienParente; ?>),
|
||||
borderColor: '#fff',
|
||||
borderWidth: 2
|
||||
}]
|
||||
},
|
||||
options: {
|
||||
responsive: true,
|
||||
maintainAspectRatio: false,
|
||||
plugins: {
|
||||
legend: {
|
||||
display: false, // On désactive la légende intégrée
|
||||
},
|
||||
datalabels: {
|
||||
formatter: (value, ctx) => {
|
||||
const sum = ctx.chart.data.datasets[0].data.reduce((a, b) => a + b, 0);
|
||||
return formatPercentage(value, sum);
|
||||
},
|
||||
color: '#fff',
|
||||
font: {
|
||||
weight: 'bold',
|
||||
size: isMobile ? 10 : 12
|
||||
}
|
||||
},
|
||||
tooltip: {
|
||||
callbacks: {
|
||||
label: function(context) {
|
||||
const label = context.label || '';
|
||||
const value = context.raw || 0;
|
||||
const sum = context.dataset.data.reduce((a, b) => a + b, 0);
|
||||
const percentage = formatPercentage(value, sum);
|
||||
return `${label}: ${formatMoney(value)} (${percentage})`;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
cutout: isMobile ? '60%' : '50%'
|
||||
},
|
||||
plugins: [ChartDataLabels]
|
||||
});
|
||||
|
||||
// Fonction pour générer une légende personnalisée sous le graphique
|
||||
function generateCustomLegend(chart, containerId) {
|
||||
const legendContainer = document.getElementById(containerId);
|
||||
legendContainer.innerHTML = '';
|
||||
|
||||
const items = chart.data.datasets[0].data.map((value, i) => {
|
||||
const total = chart.data.datasets[0].data.reduce((a, b) => a + b, 0);
|
||||
const percentage = formatPercentage(value, total);
|
||||
|
||||
return `
|
||||
<div class="d-inline-block mx-2 my-1">
|
||||
<span class="legend-color" style="
|
||||
display: inline-block;
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
background-color: ${chart.data.datasets[0].backgroundColor[i]};
|
||||
border: 1px solid #fff;
|
||||
vertical-align: middle;
|
||||
"></span>
|
||||
<span class="legend-text small ml-1">
|
||||
${chart.data.labels[i]}: ${formatMoney(value)} (${percentage})
|
||||
</span>
|
||||
</div>
|
||||
`;
|
||||
});
|
||||
|
||||
legendContainer.innerHTML = items.join('');
|
||||
}
|
||||
|
||||
// Générer la légende au chargement et lors du redimensionnement
|
||||
generateCustomLegend(distributionChart, 'pieChartLegend');
|
||||
window.addEventListener('resize', function() {
|
||||
generateCustomLegend(distributionChart, 'pieChartLegend');
|
||||
});
|
||||
</script>
|
||||
|
||||
<style>
|
||||
/* Style optionnel pour améliorer l'affichage */
|
||||
#pieChartLegend {
|
||||
font-size: 0.8rem;
|
||||
line-height: 1.4;
|
||||
}
|
||||
.legend-text {
|
||||
vertical-align: middle;
|
||||
}
|
||||
@media (max-width: 768px) {
|
||||
#pieChartLegend {
|
||||
font-size: 0.7rem;
|
||||
}
|
||||
}
|
||||
|
||||
.btn-beneficiaire {
|
||||
font-size: 10pt;
|
||||
color: blue;
|
||||
background-color: #eeeeee;
|
||||
border: 1px solid #000;
|
||||
border-radius: 3px;
|
||||
padding: 2px 5px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.photo-zoom-container {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
}
|
||||
.photo-zoom:hover {
|
||||
transform: scale(2);
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
transform: translate(-50%, -50%) scale(2);
|
||||
z-index: 1000;
|
||||
background: white;
|
||||
box-shadow: 0 0 10px rgba(0,0,0,0.2);
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
<!-- Table Section -->
|
||||
<fieldset class="mb-8">
|
||||
<legend><?= _("Membres de la famille") ?></legend>
|
||||
<div class="bg-white p-4 rounded-lg shadow-md tab-container">
|
||||
<table class="table table-striped table-bordered table-hover table-condensed table-responsive" style="font-size:8pt;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="text-center"> <?= _("Photo") ?> </th>
|
||||
<th class="text-center"> <?= _("Numéro") ?> </th>
|
||||
<th> <?= _("Nom") ?> </th>
|
||||
<th> <?=("Prénoms") ?> </th>
|
||||
<th class="text-center"> <?= _("Sexe") ?> </th>
|
||||
<th class="text-center"> <?= _("Lien") ?> </th>
|
||||
<th class="text-center"> <?= _("Né(e) le") ?> </th>
|
||||
<th class="text-center"> <?= _("Âge") ?> </th>
|
||||
<th class="text-center"> <?= ("Etat") ?> </th>
|
||||
<th class="text-center"> <?= ("Plafond") ?> </th>
|
||||
<th class="text-center"> <?= ("Conso") ?> </th>
|
||||
<th class="text-center"> <?= ("Solde") ?> </th>
|
||||
<th class="text-center"> % </th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($beneficiaires as $beneficiaire):
|
||||
$idBeneficiaire = $this->nettoyer($beneficiaire['idBeneficiaire']);
|
||||
$numeroBeneficiaire = $this->nettoyer($beneficiaire['numeroBeneficiaire']);
|
||||
$pourcent = round((100*$beneficiaire['consommation'])/$beneficiaire['plafond'],1);
|
||||
|
||||
$faceRegistered = $this->nettoyer($beneficiaire['faceRegistered']);
|
||||
$lienPhoto = $this->nettoyer($beneficiaire['lienPhoto']);
|
||||
?>
|
||||
<tr onclick="selectionner_beneficiaire(<?= $idBeneficiaire ?>, '<?= $numeroBeneficiaire ?>');"
|
||||
ondblclick="afficher_beneficiaire_id();" valign="top">
|
||||
<td align="center" style="position: relative; z-index: 1;">
|
||||
<?php if($faceRegistered == "1"): ?>
|
||||
<div class="photo-zoom-container" style="display: inline-block;">
|
||||
<img class="photoId rounded-circle photo-zoom"
|
||||
src="<?= $_SESSION['dossierPhoto_C'].$_SESSION['dossierSociete'].'/Photos/'.$lienPhoto ?>"
|
||||
alt="<?= _("Photo Bénéficiaire") ?>"
|
||||
style="width: 20px;">
|
||||
</div>
|
||||
<?php else: ?>
|
||||
<div class="photo-zoom-container" style="display: inline-block;">
|
||||
<i class="fas fa-user-circle photo-zoom"
|
||||
style="color: #ccc; font-size: 20px;"></i>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td class="text-center">
|
||||
<button type="button"
|
||||
onclick="selectionner_beneficiaire(<?= $idBeneficiaire ?>,'<?= $numeroBeneficiaire ?>');afficher_beneficiaire_id();"
|
||||
class="btn-beneficiaire">
|
||||
<?= $numeroBeneficiaire ?>
|
||||
</button>
|
||||
</td>
|
||||
<td><?= $this->nettoyer($beneficiaire['nomBeneficiaire']) ?></td>
|
||||
<td><?= $this->nettoyer($beneficiaire['prenomsBeneficiaire']) ?></td>
|
||||
<td class="text-center"><?= $this->nettoyer($beneficiaire['sexe']) ?></td>
|
||||
<td class="text-center"><?= $this->nettoyer($beneficiaire['lienparente']) ?></td>
|
||||
<td class="text-center"><?= dateFr($this->nettoyer($beneficiaire['dateNaissance'])) ?></td>
|
||||
<td class="text-center"><?= $this->nettoyer($beneficiaire['ageBeneficiaire']) ?></td>
|
||||
<td class="text-center"><?= $this->nettoyer($beneficiaire['etatbeneficiaire']) ?></td>
|
||||
<td class="text-center"><?= format_N($this->nettoyer($beneficiaire['plafond'])) ?></td>
|
||||
<td class="text-center"><?= format_N($this->nettoyer($beneficiaire['consommation'])) ?></td>
|
||||
<td class="text-center"><?= format_N($this->nettoyer($beneficiaire['soldeConsommation'])) ?></td>
|
||||
<td class="text-center"><?=$pourcent?></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</fieldset>
|
||||
|
||||
<!-- To-Do List Section -->
|
||||
<div class="mb-8">
|
||||
<div class="bg-white p-4 rounded-lg shadow-md">
|
||||
<p><i class="fas fa-file-medical text-primary"></i> <a href="javascript:afficherMasquerGaranties();" style="font-size:16pt;"><span id="span_garantie" title="<?= _("Cliquez sur le lien pour afficher ou masquer")?>"><?= _("Afficher")?></span><?= " ". _("les garanties et les dépenses de la famille")?> <i id="chevron-garantie" class="bi bi-chevron-down"></i></a></p>
|
||||
<INPUT class="sr-only" TYPE="text" id="masquerGarantie" NAME="masquerGarantie" value="1">
|
||||
<div id="div_garantie" class="tab-container">
|
||||
<div style="width:100%; margin: 5px;">
|
||||
<table class="table-responsive" style="width:100%; margin:auto; background-color: #f8f8ff; font-size:12pt;">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;"> <?= _("Légende: "); ?></td>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;"> <?= _("Consommation >= 50%"); ?></td>
|
||||
<td width="1%" style="background-color: #f8f8ff"></td>
|
||||
<td width="4%" style="background-color:#726a57"></td >
|
||||
<td width="2%" style="background-color: #f8f8ff"></td>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;"><?= _("Consommation >= 80%"); ?></td>
|
||||
<td width="1%" style="background-color: #f8f8ff"></td>
|
||||
<td width="4%" style="background-color: orange"></td >
|
||||
<td width="1%" style="background-color: #f8f8ff"></td>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;" ><?= _("Consommation = 100% / Transaction = 100%"); ?></td>
|
||||
<td style="background-color: #f8f8ff"></td>
|
||||
<td width="4%" style="background-color: red;"></td >
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div >
|
||||
<div >
|
||||
<div >
|
||||
<div class="tab-container">
|
||||
<fieldset>
|
||||
<table class="table table-striped table-bordered table-hover table-condensed table-responsive" style="font-size:10pt; white-space:nowrap;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th rowspan="2" width="5%" style="text-align:center"> <?= _("Exercice") ?> </th>
|
||||
<th rowspan="2" width="20%" style="text-align:center"> <?= _("Garantie") ?> </th>
|
||||
<th rowspan="2" style="text-align:center" width="5%"> <?= _("Taux") ?> </th>
|
||||
|
||||
<th colspan="4" style="text-align:center"> <?= _("Consommations") ?> </th>
|
||||
<th colspan="4" style="text-align:center"> <?= _("Prestations") ?> </th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th style="text-align:center" width="10%"> <?= _("Plafond") ?> </th>
|
||||
<th style="text-align:center" width="10%"> <?= _("Périodicité") ?> </th>
|
||||
<th style="text-align:center" width="10%"> <?= _("Dépenses") ?> </th>
|
||||
<th style="text-align:center" width="10%"> <?= _("Solde") ?> </th>
|
||||
|
||||
|
||||
<th style="text-align:center" width="10%"> <?= _("Nb Transaction") ?> </th>
|
||||
<th style="text-align:center" width="10%"> <?= _("Périodicité") ?> </th>
|
||||
<th style="text-align:center" width="10%"> <?= _("Nbre Prestation") ?> </th>
|
||||
<th style="text-align:center" width="10%"> <?= _("Solde") ?> </th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
<?php foreach ($garantieadherents as $v):
|
||||
$champApplication = $this->nettoyer($v['champApplication']);
|
||||
|
||||
$pourcentConsoFamille = $this->nettoyer($v['pourcentConsoFamille']);
|
||||
|
||||
$transactionFamille = $this->nettoyer($v['transactionFamille']);
|
||||
|
||||
$soldeTransactionFamille = $this->nettoyer($v['soldeTransactionFamille']);
|
||||
|
||||
$idAdherent = $this->nettoyer($v['idAdherent']);
|
||||
$codeGarantie = $this->nettoyer($v['codeGarantie']);
|
||||
$exercieReference = $this->nettoyer($v['exercieReference']);
|
||||
|
||||
$plafondFamille = format_N($this->nettoyer($v['plafondFamille']));
|
||||
|
||||
$nbreTransactionFamille = $this->nettoyer($v['nbreTransactionFamille']);
|
||||
|
||||
?>
|
||||
|
||||
<?php if($pourcentConsoFamille>='50' && $pourcentConsoFamille<'80'): ?>
|
||||
<tr style="background-color: yellow;" valign="top">
|
||||
<?php elseif($pourcentConsoFamille>='80' && $pourcentConsoFamille <'100'): ?>
|
||||
<tr style="background-color: orange;" valign="top">
|
||||
<?php elseif($pourcentConsoFamille >='100' || $transactionFamille=="1"): ?>
|
||||
<tr style="background-color: red; color:white" valign="top">
|
||||
<?php else: ?>
|
||||
<tr valign="top">
|
||||
<?php endif; ?>
|
||||
<td align='center'> <?= $this->nettoyer($v['exercieReference'])?> </td>
|
||||
<td align='center'>
|
||||
<?php if($pourcentConsoFamille >='95' || $transactionFamille=="1"): ?>
|
||||
<a title="<?= _("Plafond ou nombre de transaction atteint pour cette garantie.")?>" href="javascript:alert('Plafond ou nombre de transaction atteint pour cette garantie!');">
|
||||
<span style="color:blue; background-color:#eeeeee; border:1px solid #000; border-radius:3px;">
|
||||
<?= $this->nettoyer($v['garantie'])?>
|
||||
</span>
|
||||
</a>
|
||||
<?php else: ?>
|
||||
<?= $this->nettoyer($v['garantie'])?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td align='center'><?= $this->nettoyer($v['tauxPlafond']).'%'; ?></td>
|
||||
|
||||
<td align='center' ><?= $plafondFamille ?></td>
|
||||
<td align='center'><?= $v['codePeriodicitePlafondFamille'] ?></td>
|
||||
<td align='center'><?= format_N($this->nettoyer($v['consommationFamille'])) ?></td>
|
||||
<td align='center' ><?= format_N($this->nettoyer($v['soldeGarantieFamille'])) ?></td>
|
||||
|
||||
<td align='center'><?= $this->nettoyer($v['nbreTransactionFamille']) ?></td>
|
||||
<td align='center'><?= $v['codePeriodiciteFamille'] ?></td>
|
||||
<td align='center'><?= $this->nettoyer($v['comptePrestationFamille']) ?></td>
|
||||
<td align='center'><?= $this->nettoyer($v['soldeTransactionFamille']) ?></td>
|
||||
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr style="border:none; border-top: 3px double #333; color:#333; overflow: visible; text-align:center; height:5px;">
|
||||
<p><i class="fas fa-procedures"></i> <a href="javascript:afficherMasquerDepenses();" style="font-size:16pt;"><span id="span_depenses" title="<?= _("Cliquez sur le lien pour afficher ou masquer")?>"><?= _("Afficher") ?></span> <?= " "._("l'historique des prestations de la famille") ?> <i id="chevron-prestation" class="bi bi-chevron-down"></i> </a> </p>
|
||||
<INPUT class="sr-only" TYPE="text" id="masquerDepenses" NAME="masquerDepenses" value="1">
|
||||
<div id="div_depenses" class="tab-container">
|
||||
<table class="table table-responsive table-condensed" style='font-size:8pt;' >
|
||||
<tbody>
|
||||
<tr>
|
||||
<td > <?= _("Période du") ?> </td>
|
||||
<td ><INPUT style='text-align:center; font-size:10pt;' class="form-control datepicker" TYPE="text" id="d1" NAME="d1" value="<?= dateLang($_SESSION['dUneSemaineAvant_C'], $_SESSION['lang']) ?>" required AUTOCOMPLETE="OFF"></td>
|
||||
|
||||
<td align="center" > <?= _("Au") ?> </td>
|
||||
<td ><INPUT style='text-align:center; font-size:10pt;' class="form-control datepicker" TYPE="text" id="d2" NAME="d2" value="<?= dateCouranteLang($_SESSION['lang']) ?>" required AUTOCOMPLETE="OFF"></td>
|
||||
|
||||
<td align="center"> <?= _("Garantie") ?> </td>
|
||||
<td >
|
||||
<SELECT class="form-control" data-live-search="true" id="codeGarantie" NAME="codeGarantie"style='font-size:10pt; text-align:center;' >
|
||||
<?php liste_options_consultation($garanties, ""); ?>
|
||||
</SELECT>
|
||||
</td>
|
||||
<td colspan="2"> <button style='font-size:10pt;' type="button" class="form-control btn btn-primary" onclick="javascript:afficherhistoriqueadherent('<?= $adherent['numeroAdherent'] ?>');"><?= _("Actualiser...") ?></button> </td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div id="div_prestation" class="tab-container">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr style="border:none; border-top: 3px double #333; color:#333; overflow: visible; text-align:center; height:5px;">
|
||||
<p><i class="fas fa-tachometer-alt text-danger"></i> <a href="javascript:afficherMasquerBareme();" style="font-size:16pt;"><span id="span_bareme" title="<?= _("Cliquez sur le lien pour afficher ou masquer")?>"><?= _("Afficher") ?></span> <?= " ". _("la liste des actes médicaux plafonnés")?> <i id="chevron-plafond" class="bi bi-chevron-down"></i></a></p>
|
||||
<INPUT class="sr-only" TYPE="text" id="masquerBareme" NAME="masquerBareme" value="1">
|
||||
<div id="div_bareme">
|
||||
<legend> <?= _('Barèmes des actes plafonnés'); ?> </legend>
|
||||
<div id="div_legende_couleur" style="width:100%; margin: 5px; background-color: #f8f8ff;" class="tab-container">
|
||||
<table class="table-responsive" style="width:100%; margin:auto; background-color: #f8f8ff; font-size:12pt;">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;"> <?= _("Légende: "); ?></td>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;"> <?= _("Consommation >= 50%"); ?></td>
|
||||
<td width="1%" style="background-color: #f8f8ff"></td>
|
||||
<td width="4%" style="background-color:#726a57"></td >
|
||||
<td width="2%" style="background-color: #f8f8ff"></td>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;"><?= _("Consommation >= 80%"); ?></td>
|
||||
<td width="1%" style="background-color: #f8f8ff"></td>
|
||||
<td width="4%" style="background-color: orange"></td >
|
||||
<td width="1%" style="background-color: #f8f8ff"></td>
|
||||
<td style="font-weight:bold; text-align:right; background-color: #f8f8ff;" ><?= _("Consommation = 100% / Transaction = 100%"); ?></td>
|
||||
<td style="background-color: #f8f8ff"></td>
|
||||
<td width="4%" style="background-color: red;"></td >
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<div class="tab-container">
|
||||
<table class="table table-striped table-bordered table-hover table-condensed table-responsive" style="font-size:8pt;" >
|
||||
<thead >
|
||||
<tr>
|
||||
<th rowspan="2" style='text-align:center' width="27%"> <?= _("Actes "); ?> </th>
|
||||
<th rowspan="2" style='text-align:center'> <?= _("Taux") ?> </th>
|
||||
|
||||
<th colspan="4" style='text-align:center'> <?= _("Plafond") ?> </th>
|
||||
<th colspan="2" style='text-align:center'> <?= _("Nbre Sinistre") ?> </th>
|
||||
<th colspan="2" style='text-align:center'> <?= _("Consommations") ?> </th>
|
||||
<th colspan="2" style='text-align:center'> <?= _("Soldes") ?> </th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th style='text-align:center' width="10%"> <?= _("Valeur") ?> </th>
|
||||
<th style='text-align:center'> <?= _("Transaction") ?> </th>
|
||||
<th style='text-align:center'> <?= _("Périodicité") ?> </th>
|
||||
|
||||
<th style='text-align:center' width="7%"> <?= _("Famille") ?> </th>
|
||||
<th style='text-align:center' width="7%"> <?= _("Bénéficiaire") ?> </th>
|
||||
<th style='text-align:center' width="7%"> <?= _("Famille") ?> </th>
|
||||
<th style='text-align:center' width="7%"> <?= _("Bénéficiaire") ?> </th>
|
||||
<th style='text-align:center' width="7%"> <?= _("Famille") ?> </th>
|
||||
<th style='text-align:center' width="7%"> <?= _("Bénéficiaire") ?> </th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody style="overflow:auto; height:45px; ">
|
||||
<?php foreach ($actes as $v):
|
||||
$libelle = $this->nettoyer($v['libelle']);
|
||||
$garantie = $this->nettoyer($v['garantie']);
|
||||
$codeGarantie = $this->nettoyer($v['codeGarantie']);
|
||||
$periodicite = $this->nettoyer($v['codePeriodicite']);
|
||||
|
||||
if (est_anglophone())
|
||||
{
|
||||
$libelle = $this->nettoyer($v['libelleEng']);
|
||||
$garantie = $this->nettoyer($v['garantieEng']);
|
||||
|
||||
}
|
||||
$pourcentConsoFamille = $this->nettoyer($v['pourcentConsoFamille']);
|
||||
$pourcentConso = $this->nettoyer($v['pourcentConso']);
|
||||
$transactionFamille = $this->nettoyer($v['transactionFamille']);
|
||||
$transactionBeneficiaire = $this->nettoyer($v['transactionBeneficiaire']);
|
||||
$idBeneficiaire = $this->nettoyer($v['idBeneficiaire']);
|
||||
$codeActe = $this->nettoyer($v['codeActe']);
|
||||
$exercieReference = $this->nettoyer($v['exercieReference']);
|
||||
?>
|
||||
<?php if($pourcentConso>='50' && $pourcentConso<'80'): ?>
|
||||
<tr style="background-color: yellow;" valign="top">
|
||||
<?php elseif($pourcentConso>='80' && $pourcentConso <'100'): ?>
|
||||
<tr style="background-color: orange;" valign="top">
|
||||
<?php elseif($pourcentConso >='100' || $transactionBeneficiaire=="1"): ?>
|
||||
<tr style="background-color: red; color:white" valign="top">
|
||||
<?php else: ?>
|
||||
<tr valign="top">
|
||||
<?php endif; ?>
|
||||
|
||||
<td ><?= $libelle ?></td>
|
||||
<td align='center'><?= $this->nettoyer($v['tauxPlafond'])?></td>
|
||||
|
||||
<td align='center'><?= format_N($this->nettoyer($v['forfaitPlafond']))?></td>
|
||||
<td align='center'><?= $this->nettoyer($v['nbreTransaction'])?></td>
|
||||
<td align='center'><?= $periodicite; ?></td>
|
||||
|
||||
<td align='center'><?= format_N($this->nettoyer($v['comptePrestationFamille'])) ?></td>
|
||||
<td align='center'><?= format_N($this->nettoyer($v['comptePrestation'])) ?></td>
|
||||
<td align='center'><?= format_N($this->nettoyer($v['consommationFamille'])) ?></td>
|
||||
<td align='center'><?= format_N($this->nettoyer($v['consommation'])) ?></td>
|
||||
<td align='center'><?= format_N($this->nettoyer($v['soldeActeFamille'])) ?></td>
|
||||
<td align='center'><?= format_N($this->nettoyer($v['soldeActe'])) ?></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user