aboutsummaryrefslogtreecommitdiff
path: root/modern/src/map/MapPositions.js
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-05-28 07:37:24 -0700
committerAnton Tananaev <anton@traccar.org>2022-05-28 07:37:24 -0700
commit47fdc633966a8f2baefb5424042de6be2ecd1ab6 (patch)
tree9817e5b02898636f146c4ed7c62aa8221310bb6f /modern/src/map/MapPositions.js
parentab26340ead6eba063734286a374101951d08688b (diff)
downloadtrackermap-web-47fdc633966a8f2baefb5424042de6be2ecd1ab6.tar.gz
trackermap-web-47fdc633966a8f2baefb5424042de6be2ecd1ab6.tar.bz2
trackermap-web-47fdc633966a8f2baefb5424042de6be2ecd1ab6.zip
Add map to stops report
Diffstat (limited to 'modern/src/map/MapPositions.js')
-rw-r--r--modern/src/map/MapPositions.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/modern/src/map/MapPositions.js b/modern/src/map/MapPositions.js
index 170a6b11..4b53255a 100644
--- a/modern/src/map/MapPositions.js
+++ b/modern/src/map/MapPositions.js
@@ -1,11 +1,11 @@
import { useCallback, useEffect } from 'react';
import { useSelector } from 'react-redux';
-import { map } from './core/Map';
+import { map } from './core/MapView';
import { getStatusColor } from '../common/util/formatter';
import usePersistedState from '../common/util/usePersistedState';
-const MapPositions = ({ positions, onClick }) => {
+const MapPositions = ({ positions, onClick, showStatus }) => {
const id = 'positions';
const clusters = `${id}-clusters`;
@@ -20,7 +20,7 @@ const MapPositions = ({ positions, onClick }) => {
deviceId: position.deviceId,
name: device.name,
category: device.category || 'default',
- color: getStatusColor(device.status),
+ color: showStatus ? getStatusColor(device.status) : 'neutral',
};
};