From 88b6a03a9cf72d2cf44f6f8b6f96a61ce53404b7 Mon Sep 17 00:00:00 2001 From: Xor290 Date: Wed, 17 Jun 2026 09:47:52 +0200 Subject: [PATCH] chore: build --- frontend-prep/src/pages/User/OrderDetails.tsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/frontend-prep/src/pages/User/OrderDetails.tsx b/frontend-prep/src/pages/User/OrderDetails.tsx index 27bcaaa3..fd59b226 100644 --- a/frontend-prep/src/pages/User/OrderDetails.tsx +++ b/frontend-prep/src/pages/User/OrderDetails.tsx @@ -324,7 +324,7 @@ function OrderDetails() { console.log("✅ [ORDER DETAILS] Données mappées:", orderData); setOrder(orderData); - if (apiData.command_info?.command_status === "approved" && apiData.command_info?.livreur_assign) { + if (apiData.command_info?.command_status === "approved") { const r = await getOrderRatingStatus(id); if (r.rated) setRatingDone({ rating: r.rating!, comment: r.comment ?? "" }); } @@ -470,7 +470,7 @@ function OrderDetails() { )} - {order.status === "approved" && order.livreur_assign && ( + {order.status === "approved" && ( ratingDone ? (
@@ -481,7 +481,7 @@ function OrderDetails() { ) : ( ) )} @@ -803,8 +803,10 @@ function OrderDetails() { {ratingModal && (
setRatingModal(false)}>
e.stopPropagation()}> -

Noter le livreur

-

{order.livreur_assign}

+

Noter la livraison

+ {order.livreur_assign && ( +

{order.livreur_assign}

+ )}
{[1, 2, 3, 4, 5].map((star) => (