diff options
Diffstat (limited to 'web/app')
-rw-r--r-- | web/app/DeviceImages.js | 3 | ||||
-rw-r--r-- | web/app/store/MapTypes.js | 6 | ||||
-rw-r--r-- | web/app/view/map/BaseMap.js | 53 |
3 files changed, 16 insertions, 46 deletions
diff --git a/web/app/DeviceImages.js b/web/app/DeviceImages.js index af45ce9..9b837e8 100644 --- a/web/app/DeviceImages.js +++ b/web/app/DeviceImages.js @@ -22,7 +22,8 @@ Ext.define('Traccar.DeviceImages', { getImageSvg: function (color, zoom, angle, category) { var i, info, svg, width, height, rotateTransform, scaleTransform, fill; - info = Ext.getStore('DeviceImages').findRecord('key', category || 'default', 0, false, false, true); + info = Ext.getStore('DeviceImages').findRecord('key', category || 'default', 0, false, false, true) || + Ext.getStore('DeviceImages').findRecord('key', 'default', false, false, true); svg = Ext.clone(info.get('svg')); if (!svg) { svg = this.cloneDocument(info.get('svg')); diff --git a/web/app/store/MapTypes.js b/web/app/store/MapTypes.js index 0165756..1564789 100644 --- a/web/app/store/MapTypes.js +++ b/web/app/store/MapTypes.js @@ -56,6 +56,12 @@ Ext.define('Traccar.store.MapTypes', { key: 'custom', name: Strings.mapCustom }, { + key: 'googley', + name: 'Google Maps (satélite)' + }, { + key: 'googlem', + name: 'Google Maps (mapa)' + }, { key: 'customArcgis', name: Strings.mapCustomArcgis }] diff --git a/web/app/view/map/BaseMap.js b/web/app/view/map/BaseMap.js index c27a8d7..7813aa6 100644 --- a/web/app/view/map/BaseMap.js +++ b/web/app/view/map/BaseMap.js @@ -59,33 +59,6 @@ Ext.define('Traccar.view.map.BaseMap', { }) }), new ol.layer.Tile({ - title: Strings.mapBingRoad, - type: 'base', - visible: type === 'bingRoad', - source: new ol.source.BingMaps({ - key: bingKey, - imagerySet: 'Road' - }) - }), - new ol.layer.Tile({ - title: Strings.mapBingAerial, - type: 'base', - visible: type === 'bingAerial', - source: new ol.source.BingMaps({ - key: bingKey, - imagerySet: 'Aerial' - }) - }), - new ol.layer.Tile({ - title: Strings.mapBingHybrid, - type: 'base', - visible: type === 'bingHybrid', - source: new ol.source.BingMaps({ - key: bingKey, - imagerySet: 'AerialWithLabels' - }) - }), - new ol.layer.Tile({ title: Strings.mapCarto, type: 'base', visible: type === 'carto', @@ -96,31 +69,21 @@ Ext.define('Traccar.view.map.BaseMap', { }) }), new ol.layer.Tile({ - title: Strings.mapAutoNavi, + title: 'Google Maps (satélite)', type: 'base', - visible: type === 'autoNavi' || type === 'baidu', - source: new ol.source.OSM({ - url: 'https://webrd0{1-4}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}' - }) - }), - new ol.layer.Tile({ - title: Strings.mapYandexMap, - type: 'base', - visible: type === 'yandexMap', + visible: type === 'googley', source: new ol.source.XYZ({ - url: 'https://core-renderer-tiles.maps.yandex.net/tiles?l=map&x={x}&y={y}&z={z}', - projection: 'EPSG:3395', - attributions: '© <a href="https://yandex.com/maps/">Yandex</a>' + url: 'https://mt0.google.com/vt/lyrs=y&hl=en&x={x}&y={y}&z={z}&s=Ga', + attributions: '' }) }), new ol.layer.Tile({ - title: Strings.mapYandexSat, + title: 'Google Maps (mapa)', type: 'base', - visible: type === 'yandexSat', + visible: type === 'googlem', source: new ol.source.XYZ({ - url: 'https://core-sat.maps.yandex.net/tiles?l=sat&x={x}&y={y}&z={z}', - projection: 'EPSG:3395', - attributions: '© <a href="https://yandex.com/maps/">Yandex</a>' + url: 'https://mt0.google.com/vt/lyrs=m&hl=en&x={x}&y={y}&z={z}&s=Ga', + attributions: '' }) }), new ol.layer.Tile({ |