firefly-iii/resources/views/currencies/index.twig
2017-12-28 09:53:21 +01:00

70 lines
3.4 KiB
Twig

{% extends "./layout/default" %}
{% block breadcrumbs %}
{{ Breadcrumbs.render(Route.getCurrentRoute.getName) }}
{% endblock %}
{% block content %}
<div class="row">
<div class="col-lg-12 col-sm-12 col-md-12">
<div class="box">
<div class="box-header with-border">
<h3 class="box-title">{{ 'currencies'|_ }}</h3>
</div>
<div class="box-body">
<p class="text-info">
{{ 'currencies_intro'|_ }}
</p>
{% if currencies|length > 0 %}
<div style="padding-left:8px;">
{{ currencies.render|raw }}
</div>
<table class="table table-hover">
<thead>
<tr>
{% if isOwner %}
<th>&nbsp;</th>
{% endif %}
<th>{{ 'currency'|_ }}</th>
<th>{{ 'number_of_decimals'|_ }}</th>
<th>&nbsp;</th>
</tr>
</thead>
<tbody>
{% for currency in currencies %}
<tr>
{% if isOwner %}
<td>
<div class="btn-group btn-group-xs">
<a class="btn btn-default" href="{{ route('currencies.edit',currency.id) }}"><i class="fa fa-fw fa-pencil"></i></a>
<a class="btn btn-danger" href="{{ route('currencies.delete',currency.id) }}"><i class="fa fa-fw fa-trash"></i></a>
</div>
</td>
{% endif %}
<td>{{ currency.name }} ({{ currency.code }}) ({{ currency.symbol|raw }})</td>
<td>{{ currency.decimal_places }}</td>
<td class="defaultCurrency">
{% if currency.id == defaultCurrency.id %}
<span class="label label-success">{{ 'default_currency'|_ }}</span>
{% else %}
<a class="btn btn-info btn-xs"
href="{{ route('currencies.default',currency.id) }}">{{ 'make_default_currency'|_ }}</a>
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
<div style="padding-left:8px;">
{{ currencies.render|raw }}
</div>
{% endif %}
</div>
<div class="box-footer">
<a class="btn btn-success pull-right" href="{{ route('currencies.create') }}">{{ 'create_currency'|_ }}</a>
</div>
</div>
</div>
</div>
{% endblock %}