firefly-iii/resources/views/list/bills.twig
2016-01-08 13:35:27 +01:00

83 lines
3.5 KiB
Twig

<table class="table table-hover sortable">
<thead>
<tr>
<th data-defaultsort="disabled">&nbsp;</th>
<th>{{ trans('list.name') }}</th>
<th class="hidden-sm hidden-xs">{{ trans('list.matchesOn') }}</th>
<th colspan="2">{{ trans('list.matchingAmount') }}</th>
<th class="hidden-sm hidden-xs">{{ trans('list.lastMatch') }}</th>
<th class="hidden-sm hidden-xs">{{ trans('list.expectedMatch') }}</th>
<th class="hidden-sm hidden-xs">{{ trans('list.active') }}</th>
<th class="hidden-sm hidden-xs">{{ trans('list.automatch') }}</th>
<th class="hidden-sm hidden-xs">{{ trans('list.repeat_freq') }}</th>
</tr>
</thead>
<tbody>
{% for entry in bills %}
<tr>
<td>
<div class="btn-group btn-group-xs">
<a href="{{ route('bills.edit',entry.id) }}" class="btn btn-default btn-xs"><i class="fa fa-fw fa-pencil"></i></a>
<a href="{{ route('bills.delete',entry.id) }}" class="btn btn-danger btn-xs"><i class="fa fa-fw fa-trash-o"></i></a>
</div>
</td>
<td>
<a href="{{ route('bills.show',entry.id) }}" title="{{ entry.name }}">{{ entry.name }}</a>
</td>
<td class="hidden-sm hidden-xs" data-value="{{ entry.match }}">
{% for match in entry.match|split(',') %}
<span class="label label-info">{{ match }}</span>
{% endfor %}
</td>
<td data-value="{{ entry.amount_min }}">
{{ entry.amount_min|formatAmount }}
</td>
<td data-value="{{ entry.amount_max }}">
{{ entry.amount_max|formatAmount }}
</td>
{% if entry.lastFoundMatch %}
<td class="hidden-sm hidden-xs" data-value="{{ entry.lastFoundMatch.format('U') }}">
{{ entry.lastFoundMatch.formatLocalized(monthAndDayFormat) }}
</td>
{% else %}
<td class="hidden-sm hidden-xs" data-value="0">
<em>{{ 'unknown'|_ }}</em>
</td>
{% endif %}
{% if entry.nextExpectedMatch %}
<td class="hidden-sm hidden-xs" data-value="{{ entry.nextExpectedMatch.format('U') }}">
{{ entry.nextExpectedMatch.formatLocalized(monthAndDayFormat) }}
</td>
{% else %}
<td class="hidden-sm hidden-xs" data-value="0">
<em>{{ 'unknown'|_ }}</em>
</td>
{% endif %}
<td class="hidden-sm hidden-xs" data-value="{{ entry.active }}">
{% if entry.active %}
<i class="fa fa-fw fa-check"></i>
{% else %}
<i class="fa fa-fw fa-ban"></i>
{% endif %}
</td>
<td class="hidden-sm hidden-xs" data-value="{{ entry.automatch }}">
{% if entry.automatch %}
<i class="fa fa-fw fa-check"></i>
{% else %}
<i class="fa fa-fw fa-ban"></i>
{% endif %}
</td>
<td class="hidden-sm hidden-xs" data-value="{{ entry.repeat_freq }}{{ entry.skip }}">
{{ entry.repeat_freq|_ }}
{% if entry.skip > 0 %}
skips over {{ entry.skip }}
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>