diff options
author | Frederic Guillot <fred@kanboard.net> | 2017-02-18 13:38:51 -0500 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2017-02-18 13:38:51 -0500 |
commit | 49c8e5c1be15b9732023703473bb7e15864770f6 (patch) | |
tree | a4dcf83e0601fd734d44ad67e36299921959c3c2 /app/Template/column | |
parent | 948b7fbaaa58c0a825938f7e8bda9a07ec39239b (diff) |
Prevent people to remove swimlanes that contains tasks
Diffstat (limited to 'app/Template/column')
-rw-r--r-- | app/Template/column/index.php | 39 |
1 files changed, 18 insertions, 21 deletions
diff --git a/app/Template/column/index.php b/app/Template/column/index.php index 6108661b..3c60d021 100644 --- a/app/Template/column/index.php +++ b/app/Template/column/index.php @@ -15,19 +15,31 @@ data-save-position-url="<?= $this->url->href('ColumnController', 'move', array('project_id' => $project['id'])) ?>"> <thead> <tr> - <th class="column-40"><?= t('Column') ?></th> + <th><?= t('Column') ?></th> <th class="column-10"><?= t('Task limit') ?></th> - <th class="column-20"><?= t('Visible on dashboard') ?></th> - <th class="column-10"><?= t('Open tasks') ?></th> - <th class="column-10"><?= t('Closed tasks') ?></th> - <th><?= t('Actions') ?></th> + <th class="column-15"><?= t('Visible on dashboard') ?></th> + <th class="column-12"><?= t('Open tasks') ?></th> + <th class="column-12"><?= t('Closed tasks') ?></th> </tr> </thead> <tbody> <?php foreach ($columns as $column): ?> <tr data-column-id="<?= $column['id'] ?>"> <td> - <i class="fa fa-arrows-alt draggable-row-handle" title="<?= t('Change column position') ?>"></i> + <i class="fa fa-arrows-alt draggable-row-handle" title="<?= t('Change column position') ?>"></i> + <div class="dropdown"> + <a href="#" class="dropdown-menu dropdown-menu-link-icon"><i class="fa fa-cog fa-fw"></i><i class="fa fa-caret-down"></i></a> + <ul> + <li> + <?= $this->modal->medium('edit', t('Edit'), 'ColumnController', 'edit', array('project_id' => $project['id'], 'column_id' => $column['id'])) ?> + </li> + <?php if ($column['nb_open_tasks'] == 0 && $column['nb_closed_tasks'] == 0): ?> + <li> + <?= $this->modal->confirm('trash-o', t('Remove'), 'ColumnController', 'confirm', array('project_id' => $project['id'], 'column_id' => $column['id'])) ?> + </li> + <?php endif ?> + </ul> + </div> <?= $this->text->e($column['title']) ?> <?php if (! empty($column['description'])): ?> <span class="tooltip" title="<?= $this->text->markdownAttribute($column['description']) ?>"> @@ -47,21 +59,6 @@ <td> <?= $column['nb_closed_tasks'] ?> </td> - <td> - <div class="dropdown"> - <a href="#" class="dropdown-menu dropdown-menu-link-icon"><i class="fa fa-cog fa-fw"></i><i class="fa fa-caret-down"></i></a> - <ul> - <li> - <?= $this->modal->medium('edit', t('Edit'), 'ColumnController', 'edit', array('project_id' => $project['id'], 'column_id' => $column['id'])) ?> - </li> - <?php if ($column['nb_open_tasks'] == 0 && $column['nb_closed_tasks'] == 0): ?> - <li> - <?= $this->modal->confirm('trash-o', t('Remove'), 'ColumnController', 'confirm', array('project_id' => $project['id'], 'column_id' => $column['id'])) ?> - </li> - <?php endif ?> - </ul> - </div> - </td> </tr> <?php endforeach ?> </tbody> |