fix(order): ensure validated status for orders with lines and shop

This change adds a condition to filter orders by validated status
when retrieving orders with lines and shop for a specific pickup day.
This commit is contained in:
Jérémy Munsch 2026-11-14 23:00:51 +01:00
parent 8c484ae053
commit 341a66a2d1
No known key found for this signature in database
GPG key ID: 2AAECDA6B7330F91

View file

@ -59,6 +59,7 @@ class EloquentOrderRepository implements OrderRepository
return Order::query()
->with(['lines', 'shop'])
->whereDate('pickup_day', $pickupDay->format('Y-m-d'))
->where('status', OrderStatus::VALIDATED)
->get()
->all();
}