From cfb104ceac200cb338385c0f20017038050faf02 Mon Sep 17 00:00:00 2001 From: Alon Levy Date: Tue, 11 Nov 2014 17:09:34 +0200 Subject: graph: add id to links (not used yet) --- scripts/model/graph.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'scripts') diff --git a/scripts/model/graph.js b/scripts/model/graph.js index 3600d172..4b4b0069 100644 --- a/scripts/model/graph.js +++ b/scripts/model/graph.js @@ -274,10 +274,11 @@ function Graph(el) { } if (!found) { var link = { - "source": sourceNode, - "target": targetNode, - "name": name, - "state": state + source: sourceNode, + target: targetNode, + name: name, + state: state, + id: id_generator(), }; links.push(link); signal.signal(consts.APPLIED_GRAPH_DIFF, [{links: {add: [link]}}]); -- cgit v1.3.1