From 952dd081ab6064cb5e4d94b5ca8c2dcfd405d159 Mon Sep 17 00:00:00 2001 From: mdtrooper Date: Mon, 22 Feb 2016 17:17:03 +0100 Subject: [PATCH] Restore the code before the testing svg. --- pandora_console/include/class/Map.class.php | 8 ------- .../include/javascript/map/MapController.js | 21 +++++-------------- 2 files changed, 5 insertions(+), 24 deletions(-) diff --git a/pandora_console/include/class/Map.class.php b/pandora_console/include/class/Map.class.php index 5fad4f0764..62d018c1bf 100644 --- a/pandora_console/include/class/Map.class.php +++ b/pandora_console/include/class/Map.class.php @@ -145,14 +145,6 @@ abstract class Map { } ?> - - - - - - - - diff --git a/pandora_console/include/javascript/map/MapController.js b/pandora_console/include/javascript/map/MapController.js index a27cd70d52..4badbac0af 100644 --- a/pandora_console/include/javascript/map/MapController.js +++ b/pandora_console/include/javascript/map/MapController.js @@ -67,29 +67,18 @@ Return void This function paint the nodes */ MapController.prototype.paint_nodes = function() { + this._viewport.selectAll(".node") - .data(['caca']) + .data(nodes) .enter() .append("g") .attr("transform", - function(d) { return "translate(300 100)";}) + function(d) { return "translate(" + d['x'] + " " + d['y'] + ")";}) .append("circle") - .attr("id", function(d) { return "node_caca";}) + .attr("id", function(d) { return "node_" + d['id'];}) .attr("class", "node") .attr("style", "fill: rgb(50, 50, 128);") - .attr("r", "60"); - - //~ this._viewport.selectAll(".node") - //~ .data(nodes) - //~ .enter() - //~ .append("g") - //~ .attr("transform", - //~ function(d) { return "translate(" + d['x'] + " " + d['y'] + ")";}) - //~ .append("circle") - //~ .attr("id", function(d) { return "node_" + d['id'];}) - //~ .attr("class", "node") - //~ .attr("style", "fill: rgb(50, 50, 128);") - //~ .attr("r", "6"); + .attr("r", "6"); } /*