summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/Formatter/BoardSwimlaneFormatter.php7
-rw-r--r--app/Template/board/table_column.php30
-rw-r--r--app/Template/board/table_tasks.php2
3 files changed, 23 insertions, 16 deletions
diff --git a/app/Formatter/BoardSwimlaneFormatter.php b/app/Formatter/BoardSwimlaneFormatter.php
index 18db259d..17710fc3 100644
--- a/app/Formatter/BoardSwimlaneFormatter.php
+++ b/app/Formatter/BoardSwimlaneFormatter.php
@@ -97,6 +97,13 @@ class BoardSwimlaneFormatter extends BaseFormatter implements FormatterInterface
$this->calculateStatsByColumnAcrossSwimlanes($swimlane['columns']);
}
+ foreach($this->swimlanes as &$swimlane) {
+ foreach($swimlane['columns'] as $columnIndex => &$column) {
+ $column['column_nb_tasks'] = $this->swimlanes[0]['columns'][$columnIndex]['column_nb_tasks'];
+ $column['column_nb_score'] = $this->swimlanes[0]['columns'][$columnIndex]['column_score'];
+ }
+ }
+
return $this->swimlanes;
}
diff --git a/app/Template/board/table_column.php b/app/Template/board/table_column.php
index a9652a2b..f63438c3 100644
--- a/app/Template/board/table_column.php
+++ b/app/Template/board/table_column.php
@@ -19,11 +19,10 @@
<?= $this->task->getNewBoardTaskButton($swimlane, $column) ?>
<?php endif ?>
- <?php if ($swimlane['nb_swimlanes'] > 1 && ! empty($column['column_nb_tasks'])): ?>
- <span title="<?= t('Total number of tasks in this column across all swimlanes') ?>" class="board-column-header-task-count">
- (<span><?= $column['column_nb_tasks'] ?></span>)
- </span>
- <?php endif ?>
+
+ <span title="<?= t('Task count') ?>">
+ (<span id="task-number-column-<?= $column['id'] ?>"><?= $column['nb_tasks'] ?></span>)
+ </span>
<span class="board-column-title">
<?php if ($not_editable): ?>
@@ -75,16 +74,17 @@
</span>
- <?php if ($column['task_limit']): ?>
- <span title="<?= t('Task limit') ?>">
- (<span id="task-number-column-<?= $column['id'] ?>"><?= $column['nb_tasks'] ?></span>/<?= $this->text->e($column['task_limit']) ?>)
- </span>
- <?php else: ?>
- <span title="<?= t('Task count') ?>" class="board-column-header-task-count">
- (<span id="task-number-column-<?= $column['id'] ?>"><?= $column['nb_tasks'] ?></span>)
- </span>
- <?php endif ?>
- <?= $this->hook->render('template:board:column:header', array('swimlane' => $swimlane, 'column' => $column)) ?>
+ <?php if (! empty($column['column_nb_tasks'])): ?>
+ <span title="<?= t('Total number of tasks in this column across all swimlanes') ?>" class="board-column-header-task-count">
+ (
+ <span><?= $column['column_nb_tasks'] ?></span>
+ <?php if ($column['task_limit']): ?>
+ /<span title="<?= t('Task limit') ?>"><?= $this->text->e($column['task_limit']) ?></span>
+ <?php endif ?>
+ )
+ </span>
+ <?php endif; ?>
+ <?= $this->hook->render('template:board:column:header', array('swimlane' => $swimlane, 'column' => $column)) ?>
</div>
</th>
diff --git a/app/Template/board/table_tasks.php b/app/Template/board/table_tasks.php
index 7b38abca..e7452807 100644
--- a/app/Template/board/table_tasks.php
+++ b/app/Template/board/table_tasks.php
@@ -3,7 +3,7 @@
<?php foreach ($swimlane['columns'] as $column): ?>
<td class="
board-column-<?= $column['id'] ?>
- <?= $column['task_limit'] > 0 && $column['nb_tasks'] > $column['task_limit'] ? 'board-task-list-limit' : '' ?>
+ <?= $column['task_limit'] > 0 && $column['column_nb_tasks'] > $column['task_limit'] ? 'board-task-list-limit' : '' ?>
"
>