{% if app.request.locale == "ar" %} {% set locale = "en" %} {% else %} {% set locale = app.request.locale %} {% endif %} {{ "Order"|trans({}, "messages", locale) }} #{{ order.reference }} - {{ "Tickets"|trans({}, "messages", locale) }}
{% for orderElement in order.orderelements if (eventDateTicketReference == "all" or eventDateTicketReference == orderElement.eventticket.reference) and (is_granted("ROLE_ADMINISTRATOR") or is_granted("ROLE_ATTENDEE") or (is_granted("ROLE_ORGANIZER") and orderElement.belongsToOrganizer(app.user.organizer.slug)) or (is_granted("ROLE_POINTOFSALE") and orderElement.belongsToOrganizer(app.user.pointofsale.organizer.slug))) %} {% for ticket in orderElement.tickets %}
{% if ticket.reservedSeat %} {% endif %} {% if ticket.scanned %} {% endif %}
{{ "Order"|trans({}, "messages", locale) }} #{{ order.reference }}
{{ "Ticket"|trans({}, "messages", locale) }} #{{ ticket.reference }}

{{ orderElement.eventticket.eventdate.event.translate(locale).name }}

{% if orderElement.eventticket.eventdate.startdate %}
{{ "Start date"|trans({}, "messages", locale) }}
{{ orderElement.eventticket.eventdate.startdate|localizeddate('none', 'none', locale, date_timezone, date_format) }}
{% endif %} {% if orderElement.eventticket.eventdate.enddate %}
{{ "End date"|trans({}, "messages", locale) }}
{{ orderElement.eventticket.eventdate.enddate|localizeddate('none', 'none', locale, date_timezone, date_format) }}
{% endif %}
{{ "Venue / Location"|trans({}, "messages", locale) }}
{% if orderElement.eventticket.eventdate.venue %} {{ orderElement.eventticket.eventdate.venue.translate(locale).name }} {% else %} {{ "Online"|trans({}, "messages", locale) }} {% endif %}
{% if orderElement.eventticket.eventdate.event.organizer %}
{{ "Organizer"|trans({}, "messages", locale) }}
{{ orderElement.eventticket.eventdate.event.organizer.name }}
{% endif %}

{{ order.user.getCrossRoleName }} {% if order.user.hasRole("ROLE_POINTOFSALE") and order.payment.firstname and order.payment.lastname %} ({{ order.payment.firstname ~ " " ~ order.payment.lastname }}) {% endif %}

{{ "Ticket type"|trans({}, "messages", locale) }}
{{ orderElement.eventticket.name }}
{{ "Ticket price"|trans({}, "messages", locale) }}
{{ orderElement.eventticket.free ? "Free"|trans({}, "messages", locale) : ((services.getSetting('currency_position') == 'left' ? services.getSetting('currency_symbol') : '') ~ orderElement.displayUnitPrice() ~ (services.getSetting('currency_position') == 'right' ? services.getSetting('currency_symbol') : '')) }}
{% if order.getOrderElementsPriceSum(true) > 0 %}
{{ "Payment method"|trans({}, "messages", locale) }}
{{ order.paymentgateway.name }}
{% endif %}
{{ "Order date"|trans({}, "messages", locale) }}
{% if order.payment.details["TIMESTAMP"] is defined %} {{ order.payment.details["TIMESTAMP"]|localizeddate('none', 'none', locale, date_timezone, date_format) }} {% elseif order.payment.details["created"] is defined %} {{ order.payment.details["created"]|localizeddate('none', 'none', locale, date_timezone, date_format) }} {% else %} {{ order.payment.updatedAt|localizeddate('none', 'none', locale, date_timezone, date_format) }} {% endif %}

{{ services.stringifySeatLabel(ticket.reservedSeat) }}

{{ barcode({code: ticket.reference, type: 'qrcode', format: 'html'}) }}


{{ "This ticket was scanned at %scanDate%"|trans({"%scanDate%": ticket.updatedAt|localizeddate('none', 'none', locale, date_timezone, date_format)}, "messages", locale) }}

{% endfor %} {% endfor %}