Compare commits
2 Commits
200e4e873a
...
37b05bfe6a
Author | SHA1 | Date | |
---|---|---|---|
|
37b05bfe6a | ||
|
095df94e2f |
@ -12,14 +12,13 @@ if ($anneesFiscales[0] < $anneeCourante) {
|
|||||||
array_unshift($anneesFiscales, $anneeCourante);
|
array_unshift($anneesFiscales, $anneeCourante);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (f('change'))
|
$csrf_key = 'acc_select_year';
|
||||||
{
|
$form->runIf('change', function () {
|
||||||
$_SESSION['annee_recu'] = f('annee_recu');
|
$_SESSION['annee_recu'] = f('annee_recu');
|
||||||
\Paheko\Utils::redirect(f('from') ?: \Paheko\Utils::plugin_url());
|
}, $csrf_key, PLUGIN_ROOT . '/admin/index.php');
|
||||||
}
|
|
||||||
|
$tpl->assign(compact('anneesFiscales', 'csrf_key'));
|
||||||
|
|
||||||
$tpl->assign('anneesFiscales', $anneesFiscales);
|
|
||||||
$tpl->assign('annee_recu', $_SESSION['annee_recu']);
|
$tpl->assign('annee_recu', $_SESSION['annee_recu']);
|
||||||
$tpl->assign('from', qg('from'));
|
|
||||||
|
|
||||||
$tpl->display(PLUGIN_ROOT . '/templates/choix_annee.tpl');
|
$tpl->display(PLUGIN_ROOT . '/templates/choix_annee.tpl');
|
||||||
|
@ -11,8 +11,7 @@
|
|||||||
</select>
|
</select>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
<p class="submit">
|
<p class="submit">
|
||||||
{csrf_field key="acc_select_year"}
|
{csrf_field key=$csrf_key}
|
||||||
<input type="hidden" name="from" value="{$from}" />
|
|
||||||
{button type="submit" name="change" label="Changer" shape="right" class="main"}
|
{button type="submit" name="change" label="Changer" shape="right" class="main"}
|
||||||
</p>
|
</p>
|
||||||
</form>
|
</form>
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
<nav class="acc-year">
|
<nav class="acc-year">
|
||||||
<h4>Année fiscale sélectionnée :</h4>
|
<h4>Année fiscale sélectionnée :</h4>
|
||||||
<h3>{$annee_recu}</h3>
|
<h3>{$annee_recu}</h3>
|
||||||
<footer>{linkbutton label="Changer d'année fiscale" href="%s/choix_annee.php?from=%s"|args:$plugin_url,rawurlencode($self_url) shape="settings"}</footer>
|
<footer>{linkbutton label="Changer d'année fiscale" target="_dialog" href="%s/choix_annee.php"|args:$plugin_url shape="settings"}</footer>
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
<form id="formulaire_saisie" method="post" action="action.php">
|
<form id="formulaire_saisie" method="post" action="action.php">
|
||||||
|
@ -1,8 +1,4 @@
|
|||||||
<?php
|
{include file="_head.tpl" title="%s"|args:$plugin.nom current="plugin_%s"|args:$plugin.id}
|
||||||
$nav = $_GET['type'];
|
|
||||||
?>
|
|
||||||
<!-- nav bar -->
|
|
||||||
{include file="%s/templates/_nav.tpl"|args:$plugin_root current_nav="%s"|args:$nav}
|
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
$fmt = new \NumberFormatter('fr_FR', \NumberFormatter::SPELLOUT);
|
$fmt = new \NumberFormatter('fr_FR', \NumberFormatter::SPELLOUT);
|
||||||
|
Loading…
Reference in New Issue
Block a user