Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@
<script src="/js/Chart.js"></script>

<script>
var editor = new Editor("pcm", "euro2016");

// var editor = new Editor("pcm", "erasmus");
// var editor = new Editor("pcm", "euro2016");
// var editor = new Editor("pcm", "5835ac7b975ad81a4ab7fa80");
var editor = new Editor("pcm", "5756d09a975a3c01a5e5b476");

</script>
</body>
</html>
4 changes: 3 additions & 1 deletion public/js/editorJQuery.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,9 @@ Editor.prototype.loadPCM = function(pcmID=false){
}

//API url : https://opencompare.org/api/get/
$.get("/pcm/"+this.pcmID, function(data) {
// or relative, local path "/get/"
// I propose to change pcmID as pcmLocation; as such the user can specify an opencompare ID or a local file
$.get("https://opencompare.org/api/get/"+this.pcmID, function(data) {
that.metadata = data.metadata; //Get metadata
that.pcm = pcmApi.loadPCMModelFromString(JSON.stringify(data.pcm)); //Load PCM
//console.log(data);
Expand Down
Loading