diff --git a/frontend-prep/src/api/api.ts b/frontend-prep/src/api/api.ts index 62a557c0..11dc6c05 100644 --- a/frontend-prep/src/api/api.ts +++ b/frontend-prep/src/api/api.ts @@ -815,7 +815,7 @@ export interface Product { category: string; unit?: string; stock: number; - prices?: Array<{ quantity: number; price: number }>; + prices?: Array<{ quantity: number; price: number; active_price?: boolean }>; media?: MediaItem[]; // ✅ CHANGÉ: string[] → MediaItem[] } diff --git a/frontend-prep/src/components/ProductCard.tsx b/frontend-prep/src/components/ProductCard.tsx index 1b233c45..871f4f8b 100644 --- a/frontend-prep/src/components/ProductCard.tsx +++ b/frontend-prep/src/components/ProductCard.tsx @@ -22,7 +22,7 @@ interface ProductCardProps { image: string; stock: number; category: string; - prices?: Array<{ quantity: number; price: number }>; + prices?: Array<{ quantity: number; price: number; active_price?: boolean }>; hasVideo?: boolean; videoUrl?: string; // ✨ Nouveau prop pour l'URL de la vidéo categoryColor?: string; diff --git a/mobile/src/components/ProductCard.tsx b/mobile/src/components/ProductCard.tsx index 1f34cd5d..599176ec 100644 --- a/mobile/src/components/ProductCard.tsx +++ b/mobile/src/components/ProductCard.tsx @@ -36,7 +36,7 @@ interface ProductCardProps { category: string; stock: number; unit?: string; - prices?: Array<{ quantity: number; price: number }>; + prices?: Array<{ quantity: number; price: number; active_price?: boolean }>; media?: Array<{ url: string; type: string }>; }; onPress: () => void;