File: /home/timetracker.panomity.com/tm.old/Resources/views/report-team-tasks.html.twig
{% extends 'reporting/layout.html.twig' %}
{% block report_title %}{{ 'report_tasks_teams'|trans({}, 'reporting') }}{% endblock %}
{% block report %}
{% set hasData = data|length > 0 %}
{% embed '@AdminLTE/Widgets/box-widget.html.twig' %}
{% import "macros/widgets.html.twig" as widgets %}
{% import "macros/progressbar.html.twig" as progress %}
{% block box_title %}
{{ 'report_tasks_teams'|trans({}, 'reporting') }}
{% endblock %}
{% block box_body_class %}tasks-team-reporting-box table-responsive{% if hasData %} no-padding{% endif %}{% endblock %}
{% block box_body %}
{% if not hasData %}
{{ widgets.nothing_found() }}
{% else %}
<table class="table table-hover dataTable">
<tr>
<th>{{ 'label.team'|trans }}</th>
<th class="text-center">{{ 'label.amount'|trans }}</th>
<th class="text-center">{{ 'label.duration'|trans }}</th>
<th class="text-center">{{ 'label.estimation'|trans }}</th>
{% if hasEstimation %}
<th class="text-center">{{ 'label.progress'|trans }}</th>
{% endif %}
<th class="text-center">{{ 'label.task_no_estimation'|trans }}</th>
<th class="text-center">{{ 'label.task_with_estimation'|trans }}</th>
<th class="text-center">{{ 'label.task_started'|trans }}</th>
<th class="text-center">{{ 'label.task_not_started'|trans }}</th>
<th class="text-center">{{ 'label.task_overdue'|trans }}</th>
</tr>
{% for id, team in data %}
<tr>
<td>
<strong>{{ team.team.name }}</strong>
</td>
<td class="text-center total">
{{ team.total }}
</td>
<td class="text-nowrap text-center">
{{ team.duration|duration }}
</td>
<td class="text-nowrap text-center">
{{ team.estimation|duration }}
</td>
{% if hasEstimation %}
<td class="text-nowrap">
{% if team.estimation > 0 %}
{{ progress.progressbar(team.estimation, team.duration|default(0), team.duration|duration ~ ' / ' ~ team.estimation|duration, '') }}
{% endif %}
</td>
{% endif %}
<td class="text-center">
{{ team.no_estimation }}
</td>
<td class="text-center">
{{ team.with_estimation }}
</td>
<td class="text-center">
{{ team.started }}
</td>
<td class="text-center">
{{ team.not_started }}
</td>
<td class="text-center{% if team.overdue > 0 %} danger{% endif %}">
{{ team.overdue }}
</td>
</tr>
{% endfor %}
<tr class="summary">
<td class="text-nowrap"> </td>
<td class="text-center total">
{{ totals.total }}
</td>
<td class="text-center">
{{ totals.duration|duration }}
</td>
<td class="text-center">
{{ totals.estimation|duration }}
</td>
{% if hasEstimation %}
<td class="text-nowrap">
{% if totals.estimation > 0 %}
{{ progress.progressbar(totals.estimation, totals.estimation_duration|default(0), totals.estimation_duration|duration ~ ' / ' ~ totals.estimation|duration, '') }}
{% endif %}
</td>
{% endif %}
<td class="text-center">
{{ totals.no_estimation }}
</td>
<td class="text-center">
{{ totals.with_estimation }}
</td>
<td class="text-center">
{{ totals.started }}
</td>
<td class="text-center">
{{ totals.not_started }}
</td>
<td class="text-center{% if totals.overdue > 0 %} danger{% endif %}">
{{ totals.overdue }}
</td>
</tr>
</table>
{% endif %}
{% endblock %}
{% endembed %}
{% endblock %}