{% extends "base.html.twig" %} {% block body %}
{% if commandes %}
{% for commande in commandes %}
commande numero : {{ commande.id}}
profil : {{commande.user.prenom}}
{{commande.montant}}
commandé le : {{commande.dateAt|date('d/m/Y')}}
{% if commande.etat== 0 %} "en cour de livraison" {% elseif commande.etat== 1 %} "expedié" {% elseif commande.etat== 2 %} "livré" {% endif %}
{% for detail in commande.detailsCommande %}
{{ detail.id}}
titre oeuvre : {{ detail.oeuvre.titre}}
prix : {{ detail.prix}}€
quantité commandé : {{ detail.quantity}}
prix total de la comande : {{ detail.prix * detail.quantity}}€
{% endfor %}
{% endfor %} {% else %}

vous n'avez pas de commandes

merci

{% endif %}
{% endblock %}