From eb2ecc9d2ee39b9de600f515234a1cc9b3bd9f6f Mon Sep 17 00:00:00 2001 From: Candid Dauth Date: Tue, 4 Oct 2016 16:54:25 +0300 Subject: [PATCH] Properly closing popups again on second click --- frontend/app/map/lines/lines.js | 2 +- frontend/app/map/markers/markers.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/app/map/lines/lines.js b/frontend/app/map/lines/lines.js index ac39568a..91891298 100644 --- a/frontend/app/map/lines/lines.js +++ b/frontend/app/map/lines/lines.js @@ -154,7 +154,7 @@ map.mapEvents.$on("clickLine", function(e, line, clickPos, evt) { var one = false; map.popups.getOpenPopups().forEach(function(popup) { - if(popup.template == "view-line.html" && popup.scope.line.id == line.id) { + if(popup.template == "map/lines/view-line.html" && popup.scope.line.id == line.id) { popup.close(); if(popup.pos.lon == clickPos.lon && popup.pos.lat == clickPos.lat) one = true; diff --git a/frontend/app/map/markers/markers.js b/frontend/app/map/markers/markers.js index 80c8663c..9596b9b7 100644 --- a/frontend/app/map/markers/markers.js +++ b/frontend/app/map/markers/markers.js @@ -102,7 +102,7 @@ map.mapEvents.$on("clickMarker", function(e, marker, evt) { var one = false; map.popups.getOpenPopups().forEach(function(popup) { - if(popup.template == "view-marker.html" && popup.scope.marker.id == marker.id) { + if(popup.template == "map/markers/view-marker.html" && popup.scope.marker.id == marker.id) { popup.close(); one = true; }