aboutsummaryrefslogtreecommitdiff
path: root/modern/src/settings
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-10-28 17:02:39 -0700
committerAnton Tananaev <anton@traccar.org>2022-10-28 17:02:39 -0700
commit17b990eabe36138a4a879deef8d03b16ee27e1ba (patch)
treeb1eb82f53012ad990163996d1ce633cbbbc19c6c /modern/src/settings
parentdd09b5c7ed235088d86ba9898261d74228b825ee (diff)
downloadtrackermap-web-17b990eabe36138a4a879deef8d03b16ee27e1ba.tar.gz
trackermap-web-17b990eabe36138a4a879deef8d03b16ee27e1ba.tar.bz2
trackermap-web-17b990eabe36138a4a879deef8d03b16ee27e1ba.zip
Change live routes config
Diffstat (limited to 'modern/src/settings')
-rw-r--r--modern/src/settings/PreferencesPage.js21
1 files changed, 12 insertions, 9 deletions
diff --git a/modern/src/settings/PreferencesPage.js b/modern/src/settings/PreferencesPage.js
index 97548cbb..6aad1153 100644
--- a/modern/src/settings/PreferencesPage.js
+++ b/modern/src/settings/PreferencesPage.js
@@ -223,6 +223,18 @@ const PreferencesPage = () => {
/>
)}
/>
+ <FormControl>
+ <InputLabel>{t('mapLiveRoutes')}</InputLabel>
+ <Select
+ label={t('mapLiveRoutes')}
+ value={attributes.mapLiveRoutes || 'none'}
+ onChange={(e) => setAttributes({ ...attributes, mapLiveRoutes: e.target.value })}
+ >
+ <MenuItem value="none">{t('sharedDisabled')}</MenuItem>
+ <MenuItem value="selected">{t('deviceSelected')}</MenuItem>
+ <MenuItem value="all">{t('notificationAlways')}</MenuItem>
+ </Select>
+ </FormControl>
<FormGroup>
<FormControlLabel
control={(
@@ -236,15 +248,6 @@ const PreferencesPage = () => {
<FormControlLabel
control={(
<Checkbox
- checked={attributes.hasOwnProperty('mapLiveRoutes') ? attributes.mapLiveRoutes : false}
- onChange={(e) => setAttributes({ ...attributes, mapLiveRoutes: e.target.checked })}
- />
- )}
- label={t('mapLiveRoutes')}
- />
- <FormControlLabel
- control={(
- <Checkbox
checked={attributes.hasOwnProperty('mapFollow') ? attributes.mapFollow : false}
onChange={(e) => setAttributes({ ...attributes, mapFollow: e.target.checked })}
/>