Skip to content

Commit

Permalink
Export JSON
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivan Pozdnyakov authored and Ivan Pozdnyakov committed Sep 14, 2015
1 parent 62b8a51 commit ea95522
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions code.js
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,11 @@ $(function () { // on dom ready

bundleCounter++;
}

function produceJSON(event){
var j = cy.elements().jsons();
console.log(j);
}

function visual_pathway(obj) {
$('#cy').cytoscape({
Expand Down Expand Up @@ -370,4 +375,5 @@ $(function () { // on dom ready
document.getElementById('delete').addEventListener('click', remove);
document.getElementById('add').addEventListener('click', add);
document.getElementById('bundle').addEventListener('click',bundle);
document.getElementById('produceJSON').addEventListener('click',produceJSON);
}); // on dom ready
1 change: 1 addition & 0 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ function dataURLtoBlob(dataURL) {
<input id="add" value="Add" type="button"/></input>
<input id="delete" value="Delete Selected Node(s)" type="button"/></input>
<input id="bundle" value="Bundle" type="button"/></input>
<input id="produceJSON" value="Export JSON" type="button"/></input>
<input id="add_neighbor" value="add another neighbor" type="button"/>
<table class="dd" id="data">
<tr>
Expand Down

0 comments on commit ea95522

Please sign in to comment.