Skip to content

Commit

Permalink
fixed disappearing report after accessing nodegroup store in SPARQLgraph
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul Cuddihy committed Mar 11, 2022
1 parent 1da07c9 commit 1aee883
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions sparqlGraphWeb/sparqlGraph/js/reporttab.js
Original file line number Diff line number Diff line change
Expand Up @@ -469,11 +469,10 @@ define([ // properly require.config'ed
editElem.remove();
}
// grab report json
var jsonStr = JSON.stringify(this.editor.getValue(), null, 4);
var json = this.editor.getValue();

// launch with new schema
this.launchEditor();
this.setReport(jsonStr);
this.launchEditor(json);
},


Expand Down Expand Up @@ -527,6 +526,7 @@ define([ // properly require.config'ed
iconlib: "fontawesome5"
};
this.editor = new JSONEditor.JSONEditor(this.editorDiv, options);
if (optReport) this.editor.setValue(optReport);
this.initValidator();

this.editor.on('ready',function() {
Expand Down Expand Up @@ -570,7 +570,7 @@ define([ // properly require.config'ed
// set the report
setReport : function(reportJsonStr) {
var json = JSON.parse(reportJsonStr);
this.editor.setValue(JSON.parse(reportJsonStr));
this.editor.setValue(json);
this.storeDialog.suggestId(json.title || "");
this.expandOrCollapseAll(false);
this.setReportAsUnchanged();
Expand Down

0 comments on commit 1aee883

Please sign in to comment.