{% extends 'base.html.twig' %} {% block title %}Commande{% endblock %} {% block body %}

Détail de la demande

Id {{ commande.id }}
Vélo concerné {{commande.reparation.intervention.velo.identifiant}}
Date de demande {{ commande.date|date('d-m-Y') }}
Piece neuves {% set totalCommandeNeuf = 0 %} {% for stockNeuf in commande.stockNeufs %}
{{stockNeuf.nomPiece}} {{stockNeuf.prixUnitaire}} euros/pièce
{% set totalCommandeNeuf = totalCommandeNeuf + stockNeuf.quantite * stockNeuf.prixUnitaire %} {% else %}
Pas de pièce neuve dans cette demande
{% endfor %}
Total pièces neuves {{totalCommandeNeuf}} euros
Pièces d'occasion {% set totalCommandeOccasion = 0 %} {% for stockOccasion in commande.stockOccasions %}
{{stockOccasion.nomPiece}} {{ stockOccasion.prixUnitaire}} euros/pièce
{% set totalCommandeOccasion = totalCommandeOccasion + stockOccasion.quantite * stockOccasion.prixUnitaire %} {% else %}
Pas de pièce d'occasion dans cette demande
{% endfor %}
Total pièces d'occasions {{totalCommandeOccasion}} euros
{% if commande.reparation.validation != null %}
La réparation est déjà validée, vous ne pouvez plus ajouter de pièces à cette réparation
{% else %}
{% endif %}
{% if is_granted("ROLE_MANAGER") %}
{{ include('commande/_delete_form.html.twig') }} Modifier
{% endif %}
{% endblock %}