Projekt

Obecné

Profil

« Předchozí | Další » 

Revize f41a4cd3

Přidáno uživatelem Václav Honzík před asi 2 roky(ů)

import menu start

re #9741

Zobrazit rozdíly:

frontend/src/features/TrackingTool/Map/pathUtils.ts
17 17
export interface MapPoint {
18 18
    id: string // unique id for react
19 19
    idx: number,
20
    active: boolean,
20
    addToPath: boolean, // whether to add the point to the path
21 21
    catalogItem: CatalogItemDto,
22 22
    type: MapPointType
23
    hidden?: boolean // if true the point will not be displayed on the map
23 24
}
24 25

  
25 26
export const isMapPointDisplayable = (mapPoint: MapPoint): boolean =>
26
    !!mapPoint.catalogItem.latitude && !!mapPoint.catalogItem.longitude
27
    !!mapPoint.catalogItem.latitude && !!mapPoint.catalogItem.longitude && !mapPoint.hidden
27 28

  
28 29
/**
29 30
 * Cartesian product of two arrays
......
59 60
                {
60 61
                    id: generateUuid(),
61 62
                    idx,
62
                    active: !!catalogItem.latitude && !!catalogItem.longitude,
63
                    addToPath: !!catalogItem.latitude && !!catalogItem.longitude,
63 64
                    catalogItem,
64 65
                    type: mapPointType,
65
                })
66
                } as MapPoint)
66 67
        )
67 68
    )
68 69
}

Také k dispozici: Unified diff