45 lines
1.6 KiB
Twig
45 lines
1.6 KiB
Twig
{% extends 'base.html.twig' %}
|
|
{% import "macros/widgets.html.twig" as widgets %}
|
|
{% import "macros/datatables.html.twig" as datatables %}
|
|
|
|
{% block page_title %}{{ 'timesheet.title'|trans }}{% endblock %}
|
|
{% block page_subtitle %}{{ 'timesheet.subtitle'|trans }}{% endblock %}
|
|
|
|
{% block main %}
|
|
{% if entries.count > 0 %}
|
|
{{ datatables.data_table_header({
|
|
'label.date': 'calendar',
|
|
'label.starttime': 'hourglass-start',
|
|
'label.endtime': 'hourglass-end',
|
|
'label.duration': 'clock-o',
|
|
'label.rate': 'money',
|
|
'label.description': 'comment-o',
|
|
'label.actions': 'pencil-square-o',
|
|
}) }}
|
|
|
|
{% for entry in entries %}
|
|
<tr>
|
|
<td>{{ entry.begin|date(kimai_context.date_1) }}</td>
|
|
<td>{{ entry.begin|date("H:i") }}</td>
|
|
{% if entry.end %}
|
|
<td>{{ entry.end|date("H:i") }}</td>
|
|
<td>{{ entry.duration|duration }}</td>
|
|
<td>{{ entry.rate|money }}</td>
|
|
{% else %}
|
|
<td>‐</td>
|
|
<td>‐</td>
|
|
<td>‐</td>
|
|
{% endif %}
|
|
<td>{{ entry.description }}</td>
|
|
<td>
|
|
{{ widgets.button_group({'repeat': '#', 'edit': '#', 'trash': '#'}) }}
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
|
|
{{ datatables.data_table_footer(entries, 'timesheet_paginated') }}
|
|
{% else %}
|
|
{{ widgets.callout('warning', 'error.no_entries_found') }}
|
|
{% endif %}
|
|
{% endblock %}
|