summaryrefslogtreecommitdiff
path: root/app/Template/tag/index.php
blob: 834e8e7cffd77a27cf11ceef8a767e7de0797b22 (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
<div class="page-header">
    <h2><?= t('Global tags') ?></h2>
    <ul>
        <li>
            <?= $this->modal->medium('plus', t('Add new tag'), 'TagController', 'create') ?>
        </li>
    </ul>
</div>

<?php if (empty($tags)): ?>
    <p class="alert"><?= t('There is no global tag at the moment.') ?></p>
<?php else: ?>
    <table class="table-striped table-scrolling">
        <tr>
            <th class="column-80"><?= t('Tag') ?></th>
            <th><?= t('Action') ?></th>
        </tr>
        <?php foreach ($tags as $tag): ?>
            <tr>
                <td><?= $this->text->e($tag['name']) ?></td>
                <td>
                    <?= $this->modal->medium('edit', t('Edit'), 'TagController', 'edit', array('tag_id' => $tag['id'])) ?>
                    <?= $this->modal->confirm('trash-o', t('Remove'), 'TagController', 'confirm', array('tag_id' => $tag['id'])) ?>
                </td>
            </tr>
        <?php endforeach ?>
    </table>
<?php endif ?>