{% import "macros/widgets.html.twig" as widgets %} {% extends 'export/layout.html.twig' %} {% set columnTitles = {} %} {% set columns = { 'date': true, 'username': false, 'customer': true, 'project': true, 'activity': true, 'description': false, 'exported': false, 'tags': false, } %} {% for id, metaField in metaFields %} {% set columns = columns|merge({ (metaField): true}) %} {% set columnTitles = columnTitles|merge({ (metaField): (metaField)}) %} {% endfor %} {% set columns = columns|merge({ 'hourlyRate': false, 'fixedRate': false, 'duration': 'label.duration', 'rate': 'label.rate', }) %} {% block javascripts %} {% endblock %} {% block styles %} {% endblock %} {% block export %}
{{ 'export.period'|trans }}: {{ query.begin|date_short }} - {{ query.end|date_short }}
{{ 'label.customer'|trans }} | {{ 'label.project'|trans }} | {{ 'label.duration'|trans }} | {{ 'label.rate'|trans }} |
---|---|---|---|
{{ customerDuration|duration }} | {{ customerRate|money(customerCurrency) }} | ||
{{ summary.customer }} | {{ summary.project }} | {{ summary.duration|duration }} | {{ summary.rate|money(summary.currency) }} |
{{ customerDuration|duration }} | {{ customerRate|money(customerCurrency) }} |
{{ columnTitles[columnId]|default('label.'~columnId)|trans }} | {% endfor %}||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
{{ entry.begin|date_time }}
{{ entry.end|date_time }} |
{{ widgets.username(entry.user) }} | {{ entry.project.customer.name }} | {{ entry.project.name }} | {{ entry.activity.name }} | {% if entry.description is not empty %} {{ entry.description|escape|desc2html }} {% endif %} | {% if entry.exported %} {{ 'entryState.exported'|trans }} {% else %} {{ 'entryState.not_exported'|trans }} {% endif %} | {% if entry.tags is not empty %} {{ entry.tagsAsArray|join(', ') }} {% endif %} | {% for id, metaFieldName in metaFields %}{% set metaField = entry.metaField(metaFieldName) %} {% if not metaField is null and metaField.visible %} {{ metaField.value }} {% endif %} | {% endfor %}{{ entry.hourlyRate|money(entry.project.customer.currency) }} | {{ entry.fixedRate|money(entry.project.customer.currency) }} | {{ entry.duration|duration }} | {{ entry.rate|money(entry.project.customer.currency) }} |
{% endif %} {% endfor %} | {{ timeWorked|duration }} | {% if currency is not null and currency is not same as(false) %} {{ rateTotal|money(currency) }} {% else %} {{ rateTotal|money }} {% endif %} |