Commit 2b610792 authored by Antony Le Courtes's avatar Antony Le Courtes
Browse files

Correction bug #41532

parent 6d281fb7
Loading
Loading
Loading
Loading
+5 −1
Changes for module/Application/view/application/parametre/annees.phtml: 5 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -6,7 +6,11 @@
 * @var $canEdit boolean
 */

use Application\Provider\Privilege\Privileges;

$annees  = array_chunk($annees, 10);
$canEdit = $this->isAllowed(Privileges::getResourceId(Privileges::PARAMETRES_ANNEES_EDITION));


?>
<h1 class="page-header">Gestion des années</h1>
@@ -16,7 +20,7 @@ $annees = array_chunk($annees, 10);
        <?php foreach ($al as $annee): ?>

            <div style="margin:5px">
                <button type="button" data-id="<?= $annee->getId() ?>" class="btn btn-annee <?= $annee->isActive() ? 'btn-info active' : 'btn-default' ?>"><?= $annee ?></button>
                <button type="button" <?= (!$canEdit) ? 'disabled="disabled"' : ''; ?> data-id="<?= $annee->getId() ?>" class="btn btn-annee <?= $annee->isActive() ? 'btn-info active' : 'btn-default' ?>"><?= $annee ?></button>
            </div>

        <?php endforeach; ?>