🎯 [PRODUCTION] Using PostgreSQL DASHBOARD_MESSAGES table 🔍 [PRODUCTION] Raw messages from DB: 2 items: [ { id: 16, title: 'Mise à jour Prix', content: 'Merci de mettre vos prix a jour tous les matins, certain magasin ne le font pas.', type: 'success', storeId: null, createdBy: 'admin', createdAt: 2025-08-18T10:45:08.585Z }, { id: 8, title: 'Bon de Livraison', content: 'Lorsque vous rentrez un numéro de bon de livraison, faite le a l identique, même les majuscules. Pour My candy Shop, prendre le numéro de commande.', type: 'info', storeId: null, createdBy: 'admin_local', createdAt: 2025-08-07T11:04:38.123Z } ] 🔍 [PRODUCTION] Looking for user with username: admin 🔍 [PRODUCTION] Looking for user with username: admin_local 🔍 [PRODUCTION] User search result: Found 🔍 [PRODUCTION] User search result: Not found ❌ [PRODUCTION] User not found with username: admin_local 🎯 [PRODUCTION] Found announcements: 2 GET /api/announcements 304 in 8ms GET /api/groups 200 in 4ms GET /api/user 304 in 7ms 📊 Calcul statistiques mensuelles: { year: 2025, month: 9, startDate: '2025-09-01', endDate: '2025-10-01', groupIds: [ 1 ] } Orders API called with: { startDate: '2025-09-01', endDate: '2025-09-30', storeId: '1', userRole: 'manager' } 🔍 Non-admin orders - filtering by accessible store: { userId: '_1754943032954', role: 'manager', requestedStoreId: 1 } Deliveries API called with: { startDate: '2025-09-01', endDate: '2025-09-30', storeId: '1', withBL: undefined, userRole: 'manager' } 🔍 Non-admin deliveries - filtering by accessible store: { userId: '_1754943032954', role: 'manager', requestedStoreId: 1 } 📋 API PUBLICITIES REQUEST: { year: '2025', filterYear: 2025, storeId: undefined, userRole: 'manager' } 📋 CALLING storage.getPublicities: { filterYear: 2025, groupIds: [ 1 ] } 📋 PUBLICITES FETCHED: 29 résultats pour année 2025 🔍 PREMIERS RESULTATS: [ '1. N°2501 - Blanc', '2. N°2502 - Moins de 1€ 2€ 3€ 4€ 5€', '3. N°2503 - Imbattables' ] 📋 PUBLICITIES RETURNED: { count: 29 } GET /api/publicities 304 in 22ms 📊 Statistiques calculées: { ordersCount: 12, deliveriesCount: 10, pendingOrdersCount: 10, averageDeliveryTime: 3.6666666666666665, totalPalettes: 29, totalPackages: 3 } GET /api/stats/monthly 200 in 31ms Orders returned: 12 items GET /api/orders 200 in 33ms Deliveries returned: 10 items GET /api/deliveries 304 in 34ms GET /api/user 304 in 5ms GET /api/user 304 in 3ms HEAD /api/health 200 in 1ms Orders API called with: { startDate: undefined, endDate: undefined, storeId: undefined, userRole: 'manager' } 🔍 Manager orders - using assigned store automatically: { userId: '_1754943032954', role: 'manager', assignedStore: 1, allUserGroups: [ 1 ] } GET /api/suppliers 200 in 8ms GET /api/user 304 in 9ms 🔗 PRODUCTION: getOrders() récupéré 56 commandes avec relations Orders returned: 56 items