Amélioration navigation ; correction erreur date

FossilOrigin-Name: 21a10381cd0e6acfae85483ee95ca78652bf5671d731f7fb289e225626c26fdb
This commit is contained in:
engel 2023-02-04 15:32:03 +00:00
parent 44d37ae3bd
commit 6b000bc5bd
3 changed files with 64 additions and 26 deletions

View file

@ -6,11 +6,16 @@ use Garradin\Plugin\RecusFiscaux\Personne;
use Garradin\Plugin\RecusFiscaux\Utils;
// vérifier si le taux de réduction a été sélectionné au préalable
$_SESSION['taux_reduction'] = f('taux_reduction');
if (! isset($_SESSION['taux_reduction']) || $_SESSION['taux_reduction'] == "")
$taux = f('taux_reduction');
if (! isset($_SESSION['taux_reduction'])
&&
null === $taux)
{
\Garradin\Utils::redirect(PLUGIN_URL . 'index.php');
}
if (null !== $taux) {
$_SESSION['taux_reduction'] = $taux;
}
// versements par personne
$_SESSION['lesVersements'] = Utils::getVersementsPersonnes(
@ -21,6 +26,7 @@ $_SESSION['lesVersements'] = Utils::getVersementsPersonnes(
// préparation de l'affichage
$tpl->assign('lesVersements', $_SESSION['lesVersements']);
$tpl->assign('annee_recu', $_SESSION['annee_recu']);
$tpl->assign('plugin_css', ['style.css']);
// envoyer au template