Fixed openstreetmap support in device not using custom tiles (#9536)

* Fixed openstreetmap support in device not using custom tiles

* Updated blade template for locations

* Removed console.log()
This commit is contained in:
Neil Lathwood
2018-12-16 14:56:29 +00:00
committed by Tony Murray
parent fad0bffc43
commit dd695dde53
5 changed files with 8 additions and 8 deletions

View File

@@ -141,7 +141,8 @@ if ($device['location_id']) {
$("#toggle-map").on("shown.bs.collapse", function () {
if (device_marker == null) {
device_location = new L.LatLng(' . (float)$location->lat . ', ' . (float)$location->lng . ');
device_map = init_map("location-map", "' . $maps_engine . '", "' . $maps_api . '");
config = {"tile_url": "'.Config::get('leaflet.tile_url', '{s}.tile.openstreetmap.org').'"};
device_map = init_map("location-map", "' . $maps_engine . '", "' . $maps_api . '", config);
device_marker = init_map_marker(device_map, device_location);
device_map.setZoom(18);
';