{% extends 'admin/@layout.html.twig' %} {% set pageName = 'page_name_currency_index'|trans({}, 'admin') %} {% block content %}
{{ 'enabled_currencies'|trans({}, 'admin') }}
{{ 'button_download_actual_exchange_rates'|trans({}, 'admin') }}
{% if shopCurrencies|length %} {% for currency in shopCurrencies %} {{ _self.enableCurrencyTableRow(currency) }} {% endfor %} {% else %} {{ component('alert', {type: 'info', message: 'alert_no_enabled_currencies', translationDomain: 'admin'}) }} {% endif %}
{{ 'available_currencies'|trans({}, 'admin') }}
{% if availableCurrencies|length %} {% for currency in availableCurrencies %} {{ _self.availableCurrencyTableRow(currency) }} {% endfor %} {% else %} {{ component('alert', {type: 'info', message: 'alert_no_available_currencies', translationDomain: 'admin'}) }} {% endif %}
{% endblock %} {% macro availableCurrencyTableRow(currency) %} {{ currency.name }} {{ currency.isoCode }} {{ currency.symbol }} {{ 'button_add'|trans({}, 'admin') }} {% endmacro %} {% macro enableCurrencyTableRow(shopCurrency) %} {% set currency = shopCurrency.currency %} {{ currency.name }} {{ currency.symbol }} {{ 'button_remove'|trans({}, 'admin') }} {% endmacro %}