Order {{ order.id }}
{% if (current_user.id == order.courrier_id and (not order.stoptime)) or current_user.is_admin() -%}
Close
{%- endif %}
Courrier: {{ order.courrier.username }}
{% if order.courrier == None %}
Volunteer
{% endif %}
Location:
{{ order.location.name }}
Starttime: {{ order.starttime }}
Stoptime: {{ order.stoptime }}
Total price: {{ total_price|euro }}
Orders
{% for item in order.items %}
{{ item.user.username }} - {{ item.product.name }} - {{ item.product.price|euro }}
{% if item.can_delete(order.id, current_user.id) -%}
{%- endif %}
{% endfor %}
Debts
{% for key, value in total_payments.items() %}
{{ key.username }} - {{ value|euro }}
{% endfor %}