mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-30 01:05:39 +02:00
Restore the code before the testing svg.
This commit is contained in:
parent
c66445d3a5
commit
952dd081ab
@ -145,14 +145,6 @@ abstract class Map {
|
|||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" pointer-events="all" width="<?php echo $width;?>" height="<?php echo $height;?>">
|
<svg xmlns="http://www.w3.org/2000/svg" pointer-events="all" width="<?php echo $width;?>" height="<?php echo $height;?>">
|
||||||
<g class="viewport2">
|
|
||||||
<g class="first">
|
|
||||||
<circle cx="100" cy="100" r="90" fill="green"></circle>
|
|
||||||
</g>
|
|
||||||
<g class="second">
|
|
||||||
<rect x="200" y="200" height="90" width="90" fill="blue"></rect>
|
|
||||||
</g>
|
|
||||||
</g>
|
|
||||||
</svg>
|
</svg>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -67,29 +67,18 @@ Return void
|
|||||||
This function paint the nodes
|
This function paint the nodes
|
||||||
*/
|
*/
|
||||||
MapController.prototype.paint_nodes = function() {
|
MapController.prototype.paint_nodes = function() {
|
||||||
|
|
||||||
this._viewport.selectAll(".node")
|
this._viewport.selectAll(".node")
|
||||||
.data(['caca'])
|
.data(nodes)
|
||||||
.enter()
|
.enter()
|
||||||
.append("g")
|
.append("g")
|
||||||
.attr("transform",
|
.attr("transform",
|
||||||
function(d) { return "translate(300 100)";})
|
function(d) { return "translate(" + d['x'] + " " + d['y'] + ")";})
|
||||||
.append("circle")
|
.append("circle")
|
||||||
.attr("id", function(d) { return "node_caca";})
|
.attr("id", function(d) { return "node_" + d['id'];})
|
||||||
.attr("class", "node")
|
.attr("class", "node")
|
||||||
.attr("style", "fill: rgb(50, 50, 128);")
|
.attr("style", "fill: rgb(50, 50, 128);")
|
||||||
.attr("r", "60");
|
.attr("r", "6");
|
||||||
|
|
||||||
//~ 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");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user