production/Vue/Ajaxderogations/index.php
2025-12-01 16:12:12 +00:00

120 lines
5.3 KiB
PHP
Executable File

<div id="div_derogations">
<table class="table table-striped table-bordered table-condensed table-responsive" style="font-size:8pt;">
<thead>
<tr>
<th style='text-align:center'> No </th>
<th style='text-align:center'> Date </th>
<th style='text-align:center'> <?= _("Dérogation") ?> </th>
<th style='text-align:center'> <?= _("Prestataire") ?> </th>
<th colspan="2" style='text-align:center'> <?= _("Bénéficiaire") ?> </th>
<th style='text-align:center'> <?= _("Répondue le") ?> </th>
<th style='text-align:center'> <?= _("Répondue par") ?> </th>
<th style='text-align:center'> <?= _("Situation") ?> </th>
<th colspan="3" style='text-align:center'> <?= _("Motif Réel / Durée jeton / Motif Assuré") ?> </th>
<th style='text-align:center'> <?= _("T M") ?> </th>
</tr>
</thead>
<tbody>
<?php foreach ($derogations as $derogation):
$idDemandederogation = $this->nettoyer($derogation['idDemandederogation']);
$codeReponseDerogation = $this->nettoyer($derogation['codeReponseDerogation']);
$numeroDerogation = $this->nettoyer($derogation['numeroDerogation']);
$vip = $this->nettoyer($derogation['vip']);
?>
<?php if ($codeReponseDerogation=='9'): ?>
<tr valign="top" style='background-color:red'>
<?php elseif ($codeReponseDerogation=='1'): ?>
<tr valign="top" style='background-color:#00ff00;'>
<?php else : ?>
<tr valign="top">
<?php endif; ?>
<td align='center'>
<?php if ($vip=='0'): ?>
<input type="button" value="<?= $numeroDerogation ?>" style="color:blue;"
onClick="javascript:consulter_derogation_2(<?= $idDemandederogation ?>);">
<?php else : ?>
<input type="button" value="<?= $numeroDerogation ?> " style="color:red"
onClick="javascrit:consulter_derogation_2(<?= $idDemandederogation ?>);">
<?php endif; ?>
</td>
<td align='center'><?= dateheureLang($this->nettoyer($derogation['dateSysteme'])) ?></td>
<td align='center'><?= $this->nettoyer($derogation['libelleDerogation']) ?></td>
<td align='center'><?= $this->nettoyer($derogation['prestataire']) ?></td>
<td align='center'>
<a title="Voir les infos bénéficiaire" href='javascript:afficheBeneficiaire("<?= $this->nettoyer($derogation['numeroBeneficiaire']) ?>");'>
<?php if ($vip=='0'): ?>
<span style="color:blue;background-color:#eeeeee; border:1px solid #000; border-radius:3px;"><?= $this->nettoyer($derogation['numeroBeneficiaire']) ?>
</span>
<?php else : ?>
<span style="color:red;background-color:#eeeeee; border:1px solid #000; border-radius:3px;"><?= $this->nettoyer($derogation['numeroBeneficiaire']) ?>
</span>
<?php endif; ?>
</a>
</td>
<?php if ($vip=='0'): ?>
<td><?= $this->nettoyer($derogation['beneficiaire']) ?></td>
<?php else : ?>
<td>
<a title="Attention Bénéficiaire VIP" href='javascript:alert_ebene("Attention Bénéficiaire VIP!", "Attention VIP Beneficiary!");'>
<span style="color:red;background-color:#eeeeee; border:1px solid #000; border-radius:3px;">
<?= $this->nettoyer($derogation['beneficiaire']) ?>
</span>
</a>
</td>
<?php endif; ?>
<!--
<td align='center'><?= $this->nettoyer($derogation['numeroBeneficiaire']) ?></td>
<td><?= $this->nettoyer($derogation['beneficiaire']) ?></td>
-->
<td align='center'><?= dateheureLang($this->nettoyer($derogation['dateReponse'])) ?></td>
<td align='center'><?= $this->nettoyer($derogation['responsableDerogation']) ?></td>
<td align='center'><?= $this->nettoyer($derogation['reponseDerogation']) ?></td>
<?php if ($codeReponseDerogation=='0'): ?>
<td align="center" colspan="2">
<?php if ($vip=='0'): ?>
<input style="color:blue;" type="button" value="<?= _("Accepter") ?>"
onClick="javascript:accepter_derogation_2(<?= $idDemandederogation ?>);">
<?php else : ?>
<input style="color:blue;" type="button" value="<?= _("Accepter") ?>"
onClick="javascript:alertvip('A','derogation', <?= $idDemandederogation ?>);">
<?php endif; ?>
</td>
<td align="center">
<?php if ($vip=='0'): ?>
<input style="color:red;" type="button" value="<?= _("Refuser") ?>"
onClick="javascript:refuser_derogation_2(<?= $idDemandederogation ?>);">
<?php else : ?>
<input style="color:red;" type="button" value="<?= _("Refuser") ?>"
onClick="javascript:alertvip('R','derogation', <?= $idDemandederogation ?>);">
<?php endif; ?>
</td>
<?php elseif($codeReponseDerogation=='1'): ?>
<td align='center'><?= $this->nettoyer($derogation['motifReel']) ?></td>
<td align='center'><?= dateLang($this->nettoyer($derogation['debut'])) ?></td>
<td align='center'><?= dateLang($this->nettoyer($derogation['fin'])) ?></td>
<?php elseif($codeReponseDerogation=='9'): ?>
<td align='center'><?= $this->nettoyer($derogation['motifReel']) ?></td>
<td align='center' colspan="2"><?= $this->nettoyer($derogation['motifRefusAssure']) ?></td>
<?php endif; ?>
<td align='center'><?= $this->nettoyer($derogation['tmDerogation']) ?></td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>