From 363dedaedd6e0fd4d8e70141e01d8ba73f377b46 Mon Sep 17 00:00:00 2001 From: Megala Date: Tue, 6 Dec 2016 17:29:41 +0530 Subject: [PATCH] Adding the focus point for map --- .../GadgetGeoDashboard_1.0.0/geo-dashboard/js/websocket.js | 1 + 1 file changed, 1 insertion(+) diff --git a/components/analytics/iot-analytics/org.wso2.carbon.iot.geo.dashboard/src/main/resources/carbonapps/GadgetGeoDashboard_1.0.0/geo-dashboard/js/websocket.js b/components/analytics/iot-analytics/org.wso2.carbon.iot.geo.dashboard/src/main/resources/carbonapps/GadgetGeoDashboard_1.0.0/geo-dashboard/js/websocket.js index 5121241533..72fb6f7f21 100644 --- a/components/analytics/iot-analytics/org.wso2.carbon.iot.geo.dashboard/src/main/resources/carbonapps/GadgetGeoDashboard_1.0.0/geo-dashboard/js/websocket.js +++ b/components/analytics/iot-analytics/org.wso2.carbon.iot.geo.dashboard/src/main/resources/carbonapps/GadgetGeoDashboard_1.0.0/geo-dashboard/js/websocket.js @@ -138,6 +138,7 @@ SpatialObject.prototype.update = function (geoJSON) { if (selectedSpatialObject == this.id) { this.updatePath([geoJSON.geometry.coordinates[1], geoJSON.geometry.coordinates[0]]); chart.load({columns: [this.speedHistory.getArray()]}); + map.setView([this.latitude, this.longitude]); } // TODO: use general popup DOM