{% set success = app['request'].query.get('success') %} {% set action = app['request'].query.get('action') %}
{% if success == '1' %}
{% if action == 'order' %} {{ 'The records have been properly ordered' | trans }} {% elseif action == 'send' %} {{ 'Order has been sent' | trans }} {% elseif action == 'deny' %} {{ 'Order has been denied' | trans }} {% endif %}
{% elseif success == '0' %}
{{ 'An error occured, please retry or contact an admin if problem persists' | trans }}
{% endif %}
{% if orders_todo|length > 0 %} {% for order in orders_todo %} {% set deadline = order.getDeadline()|date('d/m/Y') %} order.getDeadline() ? "style=color:#777": "" }}> {% endfor %} {% else %} {% endif %}
{{ 'order-manager::order-list: order-id' | trans }} {{ order.getId() }}

{{ order.getOrderUsage() | nl2br }}

{{ order.getUser().getEmail() }}
{{ 'Date de demande' | trans }} {{ order.getCreatedOn()|date('d/m/Y') }} {{ 'Deadline' | trans }} {% if deadline != '' %} {{deadline}} {% else %} {{ 'Aucune' | trans }} {% endif %} {{ 'order-manager::order-list: treated-documents' | trans }} {{ order.getTotalTreatedItems() }}/{{ order.getTotal() }}
{{ 'order-manager::order-list: no-result' | trans }}
{% if orders_processed|length > 0 %} {% for order in orders_processed %} {% set deadline = order.getDeadline()|date('d/m/Y') %} order.getDeadline() ? "style=color:#777": "" }}> {% endfor %} {% else %} {% endif %}
{{ 'order-manager::order-list: order-id' | trans }} {{ order.getId() }}

{{ order.getOrderUsage() | nl2br }}

{{ order.getUser().getEmail() }}
{{ 'Date de demande' | trans }} {{ order.getCreatedOn()|date('d/m/Y') }} {{ 'Deadline' | trans }} {% if deadline != '' %} {{deadline}} {% else %} {{ 'Aucune' | trans }} {% endif %} {{ 'order-manager::order-list: treated-documents' | trans }} {{ order.getTotalTreatedItems() }}/{{ order.getTotal() }} {% if order.getTodo() == 0 and order.getCanceledOn() is not empty %} {{ 'order-manager:: cancel' | trans }} {{ 'order-manager:: canceled on %canceled_on% by %canceled_by%, with %n% items not treated' | trans({'%canceled_on%' : order.getCanceledOn() | date('d/m/Y'), '%canceled_by%' : user_display_name(order.getCanceledBy()), '%n%' : order.getCanceledTodo()}) }} {% endif %}
{{ 'order-manager::order-list: no-result' | trans }}