{# /** * @file * Template for the coupon redemption form. * * Available variables: * - form: The form. Contains the currently applied coupons in form.coupons, * each containing a code, display_name, remove_button. * For example: form.coupons.0.code. * * @ingroup themeable */ #} {% if form.coupons|length %} {% if form['#cardinality'] == 1 %}


{{ 'You applied the coupon %code to the order.'|t({'%code': form.coupons.0.code|render}) }}

{{ form.coupons.0.remove_button }}
{% else %}

{{ 'Applied coupons'|t }}

{% for key, coupon in form.coupons if key|first != '#' %} {% endfor %}
{{ coupon.code }} {{ coupon.remove_button }}
{% endif %} {% endif %} {{ form|without('coupons') }}