aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2019-07-14 23:05:43 -0700
committerGitHub <noreply@github.com>2019-07-14 23:05:43 -0700
commit37e28a7569d38f5aa2b1a18cf188b969347717b0 (patch)
tree5373469d62c04ac8c370c7b2ab47a63cf2101ac5
parent74045badac73aae991301e65d119109ee7d5d46e (diff)
parent3b0f7304db66d560e241511f3c9dc6ebaf31013d (diff)
downloadtrackermap-web-37e28a7569d38f5aa2b1a18cf188b969347717b0.tar.gz
trackermap-web-37e28a7569d38f5aa2b1a18cf188b969347717b0.tar.bz2
trackermap-web-37e28a7569d38f5aa2b1a18cf188b969347717b0.zip
Merge pull request #749 from edvalley/proposed
Add support for custom ArcGIS REST map services
-rw-r--r--web/app/store/MapTypes.js3
-rw-r--r--web/app/view/map/BaseMap.js7
-rw-r--r--web/l10n/en.json5
3 files changed, 13 insertions, 2 deletions
diff --git a/web/app/store/MapTypes.js b/web/app/store/MapTypes.js
index 3d322438..88d54bfa 100644
--- a/web/app/store/MapTypes.js
+++ b/web/app/store/MapTypes.js
@@ -49,5 +49,8 @@ Ext.define('Traccar.store.MapTypes', {
}, {
key: 'custom',
name: Strings.mapCustom
+ }, {
+ key: 'customArcgis',
+ name: Strings.mapCustomArcgis
}]
});
diff --git a/web/app/view/map/BaseMap.js b/web/app/view/map/BaseMap.js
index 4f0c8d48..0ab48e87 100644
--- a/web/app/view/map/BaseMap.js
+++ b/web/app/view/map/BaseMap.js
@@ -46,6 +46,13 @@ Ext.define('Traccar.view.map.BaseMap', {
})
});
break;
+ case 'customArcgis':
+ layer = new ol.layer.Tile({
+ source: new ol.source.TileArcGISRest({
+ url: Ext.String.htmlDecode(server.get('mapUrl'))
+ })
+ });
+ break;
case 'bingRoad':
layer = new ol.layer.Tile({
source: new ol.source.BingMaps({
diff --git a/web/l10n/en.json b/web/l10n/en.json
index 69f3fed3..73747852 100644
--- a/web/l10n/en.json
+++ b/web/l10n/en.json
@@ -231,7 +231,8 @@
"serverForceSettings": "Force Settings",
"mapTitle": "Map",
"mapLayer": "Map Layer",
- "mapCustom": "Custom Map",
+ "mapCustom": "Custom (XYZ)",
+ "mapCustomArcgis": "Custom (ArcGIS)",
"mapCarto": "Carto Basemaps",
"mapOsm": "Open Street Map",
"mapBingKey": "Bing Maps Key",
@@ -427,4 +428,4 @@
"categoryScooter": "Scooter",
"maintenanceStart": "Start",
"maintenancePeriod": "Period"
-} \ No newline at end of file
+}