ensure name is part of click message

to close #57
This commit is contained in:
Dave Conway-Jones 2018-11-21 19:48:20 +00:00
parent e68f71d9c1
commit 7ce853145a
No known key found for this signature in database
GPG Key ID: 9E7F9C73F5168CD4
5 changed files with 5 additions and 5 deletions

View File

@ -1,6 +1,6 @@
### Change Log for Node-RED Worldmap ### Change Log for Node-RED Worldmap
- v1.5.12 - Send click message to websocket on marker click - Issue #56 - v1.5.13 - Send click message to websocket on marker click - Issue #56, #57
- v1.5.11 - Let search also try geocoding lookup if not found in marks. - v1.5.11 - Let search also try geocoding lookup if not found in marks.
- v1.5.10 - Allow latest mark added to open popup, and allow `popped=false` to close. - v1.5.10 - Allow latest mark added to open popup, and allow `popped=false` to close.
- v1.5.7 - Tidy up sidc entry, and drag-ability of nodes on drawing layer. - v1.5.7 - Tidy up sidc entry, and drag-ability of nodes on drawing layer.

View File

@ -9,7 +9,7 @@ map web page for plotting "things" on.
### Updates ### Updates
- v1.5.12 - Send click message to websocket on marker click - Issue #56 - v1.5.13 - Send click message to websocket on marker click - Issue #56, #57
- v1.5.11 - Let search also try geocoding lookup if not found in marks. - v1.5.11 - Let search also try geocoding lookup if not found in marks.
- v1.5.10 - Allow latest mark added to open popup, and allow `popped=false` to close. - v1.5.10 - Allow latest mark added to open popup, and allow `popped=false` to close.
- v1.5.7 - Tidy up sidc entry, and drag-ability of nodes on drawing layer. - v1.5.7 - Tidy up sidc entry, and drag-ability of nodes on drawing layer.

View File

@ -1,6 +1,6 @@
{ {
"name": "node-red-contrib-web-worldmap", "name": "node-red-contrib-web-worldmap",
"version": "1.5.12", "version": "1.5.13",
"description": "A Node-RED node to provide a web page of a world map for plotting things on.", "description": "A Node-RED node to provide a web page of a world map for plotting things on.",
"dependencies": { "dependencies": {
"cgi": "0.3.1", "cgi": "0.3.1",

View File

@ -1184,6 +1184,7 @@ function setMarker(data) {
}); });
marker = L.marker(ll, {title:data.name, icon:myMarker, draggable:drag}); marker = L.marker(ll, {title:data.name, icon:myMarker, draggable:drag});
} }
marker.name = data.name;
// var createLabelIcon = function(labelText) { // var createLabelIcon = function(labelText) {
// return L.marker(new L.LatLng(51.05, -1.35), {icon:L.divIcon({ html:labelText })}); // return L.marker(new L.LatLng(51.05, -1.35), {icon:L.divIcon({ html:labelText })});
@ -1191,7 +1192,6 @@ function setMarker(data) {
// send new position at end of move event if point is draggable // send new position at end of move event if point is draggable
if (data.draggable === true) { if (data.draggable === true) {
marker.name = data.name;
if (data.icon) { marker.icon = data.icon; } if (data.icon) { marker.icon = data.icon; }
if (data.iconCOlor) { marker.iconColor = data.iconColor; } if (data.iconCOlor) { marker.iconColor = data.iconColor; }
if (data.SIDC) { marker.SIDC = data.SIDC.toUpperCase(); } if (data.SIDC) { marker.SIDC = data.SIDC.toUpperCase(); }

View File

@ -1,5 +1,5 @@
CACHE MANIFEST CACHE MANIFEST
# date: Nov 9th 2018 - v1.5.12 # date: Nov 9th 2018 - v1.5.13
CACHE: CACHE:
index.html index.html