Fix: check all 4 coordinates in routesForMap filter
All checks were successful
Build Docker Image / build (push) Successful in 3m44s

This commit is contained in:
Ruslan Bakiev
2026-01-07 10:35:40 +07:00
parent bddaf6e142
commit 8e7271abf3

View File

@@ -28,7 +28,7 @@ export function useTeamOrders() {
name: order.name,
status: order.status,
stages: (order.stages || [])
.filter((s: any) => s.stageType === 'transport' && s.sourceLatitude && s.destinationLatitude)
.filter((s: any) => s.stageType === 'transport' && s.sourceLatitude && s.sourceLongitude && s.destinationLatitude && s.destinationLongitude)
.map((s: any) => ({
fromLat: s.sourceLatitude,
fromLon: s.sourceLongitude,