mirror of
https://github.com/R0m1k3/LogiFlow.git
synced 2026-10-11 17:27:31 +02:00
Display all pending orders instead of limiting to the last four
Modify the Dashboard component to display all pending orders rather than a limited subset of the last four. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 98f01874-e00c-4bbe-9d71-b0b338001848 Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/1957c339-2757-4d1f-8e92-e9f71a1ce58e/98f01874-e00c-4bbe-9d71-b0b338001848/XDIQsDu
This commit is contained in:
1 parent
6916a25822
commit
68bab78909
1 file changed
+2
-3
@@ -225,15 +225,14 @@ export default function Dashboard() {
|
||||
})
|
||||
.slice(0, 4) : []; // Afficher les 4 dernières commandes
|
||||
|
||||
// Les 4 dernières commandes en attente
|
||||
// Toutes les commandes en attente
|
||||
const pendingOrders = Array.isArray(allOrders) ? allOrders
|
||||
.filter((order: any) => order.status === 'pending')
|
||||
.sort((a: any, b: any) => {
|
||||
const dateA = safeDate(a.createdAt);
|
||||
const dateB = safeDate(b.createdAt);
|
||||
return (dateB ? dateB.getTime() : 0) - (dateA ? dateA.getTime() : 0);
|
||||
})
|
||||
.slice(0, 4) : []; // Afficher les 4 dernières commandes en attente
|
||||
}) : []; // Afficher toutes les commandes en attente
|
||||
|
||||
const upcomingDeliveries = Array.isArray(allDeliveries) ? allDeliveries
|
||||
.filter((d: any) => {
|
||||
|
||||
Reference in new issue
Block a user