aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
authorzsloan2016-09-13 16:28:37 +0000
committerzsloan2016-09-13 16:28:37 +0000
commit62cacc047ae502d7ff052466b1dcc50e4d895f3b (patch)
tree03e62d62535cbc9f9df3e15d46a1f94b792b07d5 /wqflask
parent909a1cca82d86f824c6778b59b2ee339a7ee8ffd (diff)
downloadgenenetwork2-62cacc047ae502d7ff052466b1dcc50e4d895f3b.tar.gz
Save Image now works for Network Graph and downloads current graph as a png
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/wqflask/static/new/javascript/network_graph.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/wqflask/wqflask/static/new/javascript/network_graph.js b/wqflask/wqflask/static/new/javascript/network_graph.js
index e8ca6be0..d1afd47c 100644
--- a/wqflask/wqflask/static/new/javascript/network_graph.js
+++ b/wqflask/wqflask/static/new/javascript/network_graph.js
@@ -187,8 +187,8 @@ window.onload=function() {
$("a#image_link").click(function(e) {
var pngData = cy.png();
- image_link.href = 'data:image/png;base64,' + pngData;
- image_link.download = 'network_graph.png';
+ $(this).attr('href', pngData);
+ $(this).attr('download', 'network_graph.png');
console.log("TESTING:", image_link)