2023-02-04 23:34:39 +01:00
|
|
|
{% extends "admin/base_admin.html.twig" %}
|
2019-08-12 23:45:21 +02:00
|
|
|
|
|
|
|
{% block card_title %}
|
2022-08-13 02:40:43 +02:00
|
|
|
<i class="fa-solid fa-coins"></i> {% trans %}currency.caption{% endtrans %}
|
2019-08-12 23:45:21 +02:00
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block additional_controls %}
|
|
|
|
{{ form_row(form.iso_code) }}
|
|
|
|
{% if entity.isoCode %}
|
|
|
|
<div class="mt-0 mb-3">
|
|
|
|
<span class="form-text text-muted offset-3 col-9">
|
|
|
|
<b>{% trans %}currency.iso_code.caption{% endtrans %}:</b> {{ entity.isoCode }}
|
|
|
|
</span>
|
|
|
|
<span class="form-text text-muted offset-3 col-9">
|
|
|
|
<b>{% trans %}currency.symbol.caption{% endtrans %}:</b> {{ entity.isoCode | currency_symbol }}
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
{{ form_row(form.exchange_rate) }}
|
2022-12-11 15:33:50 +01:00
|
|
|
{% if entity.inverseExchangeRate %}
|
|
|
|
<p class="form-text text-muted offset-3 col-9">
|
|
|
|
{{ '1'|format_currency(default_currency) }} = {{ entity.inverseExchangeRate.tofloat | format_currency(entity.isoCode, {fraction_digit: 5}) }}<br>
|
|
|
|
{{ '1'|format_currency(entity.isoCode) }} = {{ entity.exchangeRate.tofloat | format_currency(default_currency, {fraction_digit: 5}) }}
|
|
|
|
</p>
|
|
|
|
{% endif %}
|
|
|
|
|
2020-06-07 22:38:10 +02:00
|
|
|
|
|
|
|
{% if form.update_exchange_rate is defined %}
|
2022-12-11 15:10:16 +01:00
|
|
|
{{ form_row(form.update_exchange_rate, {attr: {class: 'btn-info'}}) }}
|
2020-06-07 22:38:10 +02:00
|
|
|
{% endif %}
|
2022-12-11 15:33:50 +01:00
|
|
|
|
|
|
|
|
2020-05-11 22:59:25 +02:00
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block edit_title %}
|
|
|
|
{% trans %}currency.edit{% endtrans %}: {{ entity.name }}
|
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block new_title %}
|
|
|
|
{% trans %}currency.new{% endtrans %}
|
2019-08-12 23:45:21 +02:00
|
|
|
{% endblock %}
|