summaryrefslogtreecommitdiff
path: root/plugins/Boardcustomizer/Template/user/settings.php
blob: 9a6e3124cbda66aa9894b49474d12ee5aae1ba9e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<div class="page-header">
    <h2><?= t('My display settings') ?></h2>
</div>


<?php if (empty($options)) : ?>
    <p class="alert"><?= t('No options') ?></p>
<?php else : ?>
    <table class="table-small table-fixed">
        <tr>
            <th class="column-40"><?= t('Option') ?></th>
            <th class="column-20"><?= t('Status') ?></th>
        </tr>
        <?php foreach ($options as $option => $key) : ?>
            <tr>
                <td>
                    <?= $option ?>
                </td>
                <td>
                    <?php if ($this->user->userMetadataModel->exists($user['id'], $key)) : ?>
                        <?= $this->url->icon('toggle-off', t('Disable'), 'SettingsController', 'disable', array('plugin' => 'boardcustomizer', 'key' => $key), true) ?>
                    <?php else : ?>
                        <?= $this->url->icon('toggle-on', t('Enable'), 'SettingsController', 'enable', array('plugin' => 'boardcustomizer', 'key' => $key), true) ?>
                    <?php endif ?>
                </td>
            </tr>
        <?php endforeach ?>
    </table>
<?php endif ?>