From 7bfc647ed873322c1fb5f5e3401c578695c469ad Mon Sep 17 00:00:00 2001 From: Erik Perrone Date: Tue, 20 Feb 2018 15:41:48 +0000 Subject: [PATCH] git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/data-analysis/nlphub@164452 82a268e6-3cf1-43bd-a215-b396298e98cf --- src/main/webapp/index.jsp | 47 ++++++++++++++++++++++++++++++++++++--- 1 file changed, 44 insertions(+), 3 deletions(-) diff --git a/src/main/webapp/index.jsp b/src/main/webapp/index.jsp index ad7235d..5c2f4fe 100644 --- a/src/main/webapp/index.jsp +++ b/src/main/webapp/index.jsp @@ -27,6 +27,7 @@ var publicLink = null; var pageGreen = "#4CAF50"; var pageGray = "#A0A0A0"; + var savedAnnotations = ""; $("#execute-button").css("background-color", pageGray); // ------------------------------------------------------------------------------------------------------ @@ -63,6 +64,7 @@ onLoad : function(obj) { $("#file-info").remove(); $("#fu-container").append("
"); + savedAnnotations = ""; }, onSuccess : function(files, data, xhr) { console.log("files: " + files); @@ -241,6 +243,7 @@ annList += list[i] + ","; } annList = annList.substring(0, annList.length-1); + savedAnnotations = annList; var algList = ""; for(j in algorithms) { @@ -259,10 +262,10 @@ url : "/nlphub/nlphub-servlet?" + parameters, type : "POST", async : true, - //contentType : "text/plain; charset=utf-8", success : function(data, stato) { - if(typeof(data.response) != 'undefined') - alert(data.message); + if(typeof(data.response) != 'undefined') { + var jsonOut = getOutputJson(data.message); + } else if (typeof(data.error) != 'undefined') alert(data.message); else @@ -273,6 +276,44 @@ } }); + //publicLink = null; + } + + getOutputJson = function(message) { + var tobemap = ""; + for(var i=0; i