Add new analytic component "Estimated vs actual time per column"
This commit is contained in:
committed by
GitHub
parent
6cadf82a63
commit
a267aa368b
30
app/Template/analytic/estimated_actual_column.php
Normal file
30
app/Template/analytic/estimated_actual_column.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php if (! $is_ajax): ?>
|
||||
<div class="page-header">
|
||||
<h2><?= t('Estimated vs actual time per column') ?></h2>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
|
||||
<?php if (empty($metrics)): ?>
|
||||
<p class="alert"><?= t('Not enough data to show the graph.') ?></p>
|
||||
<?php else: ?>
|
||||
<?= $this->app->component('chart-project-estimated-actual-column', array(
|
||||
'metrics' => $metrics,
|
||||
'labelSpent' => t('Hours Spent'),
|
||||
'labelEstimated' => t('Hours Estimated'),
|
||||
)) ?>
|
||||
|
||||
<table class="table-striped">
|
||||
<tr>
|
||||
<th><?= t('Column') ?></th>
|
||||
<th><?= t('Hours Spent') ?></th>
|
||||
<th><?= t('Hours Estimated') ?></th>
|
||||
</tr>
|
||||
<?php foreach ($metrics as $column): ?>
|
||||
<tr>
|
||||
<td><?= $this->text->e($column['title']) ?></td>
|
||||
<td><?= $this->dt->durationHours($column['hours_spent']) ?></td>
|
||||
<td><?= $this->dt->durationHours($column['hours_estimated']) ?></td>
|
||||
</tr>
|
||||
<?php endforeach ?>
|
||||
</table>
|
||||
<?php endif ?>
|
||||
@@ -21,6 +21,9 @@
|
||||
<li <?= $this->app->checkMenuSelection('AnalyticController', 'timeComparison') ?>>
|
||||
<?= $this->modal->replaceLink(t('Estimated vs actual time'), 'AnalyticController', 'timeComparison', array('project_id' => $project['id'])) ?>
|
||||
</li>
|
||||
<li <?= $this->app->checkMenuSelection('AnalyticController', 'estimatedVsActualByColumn') ?>>
|
||||
<?= $this->modal->replaceLink(t('Estimated vs actual time per column'), 'AnalyticController', 'estimatedVsActualByColumn', array('project_id' => $project['id'])) ?>
|
||||
</li>
|
||||
|
||||
<?= $this->hook->render('template:analytic:sidebar', array('project' => $project)) ?>
|
||||
</ul>
|
||||
|
||||
Reference in New Issue
Block a user