Nils Schneider 9 years ago
parent
commit
aae9d4253e
2 changed files with 3 additions and 3 deletions
  1. 2 2
      lib/forcegraph.js
  2. 1 1
      lib/map.js

+ 2 - 2
lib/forcegraph.js

@@ -115,7 +115,7 @@ define(["d3"], function (d3) {
 
           return
         } else if (highlight.type === "link") {
-          var l = linksDict[linkId(highlight.o)]
+          var l = linksDict[highlight.o.id]
 
           if (l) {
             node.classed("highlight", false)
@@ -223,7 +223,7 @@ define(["d3"], function (d3) {
 
       link = vis.select("g.links")
                 .selectAll("g.link")
-                .data(links, function (d) { return d.id })
+                .data(intLinks, function (d) { return d.o.id })
 
       link.exit().remove()
 

+ 1 - 1
lib/map.js

@@ -118,7 +118,7 @@ define(["d3", "leaflet", "moment", "leaflet.label"], function (d3, L, moment) {
           if (m)
             m.setStyle({ fillColor: m.options.color, color: "orange", weight: 20, fillOpacity: 1, opacity: 0.7 })
         } else if (highlight.type === "link") {
-          m = linkDict[linkId(highlight.o)]
+          m = linkDict[highlight.o.id]
 
           if (m)
             m.setStyle({ weight: 7, opacity: 1, dashArray: "10, 10" })