diff --git a/src/main/webapp/ProgressWatch.jsp b/src/main/webapp/ProgressWatch.jsp
index e67f94de..30c3c6bc 100644
--- a/src/main/webapp/ProgressWatch.jsp
+++ b/src/main/webapp/ProgressWatch.jsp
@@ -119,7 +119,7 @@
fileExtensions.push("tsv");
- showServerExportBox(fileExtensions, ${param.keepExportOnServ});
+ showServerExportBox(${param.keepExportOnServ}, fileExtensions);
}
diff --git a/src/main/webapp/index.jsp b/src/main/webapp/index.jsp
index 34fbe12c..4327c681 100644
--- a/src/main/webapp/index.jsp
+++ b/src/main/webapp/index.jsp
@@ -1857,12 +1857,6 @@ https://doi.org/10.1093/gigascience/giz051
var indToExport = $('#exportedIndividuals').val() == "choose" ? $('#exportedIndividuals').parent().parent().find("select.individualSelector").val() : ($('#exportedIndividuals').val() == "allGroups" ? getSelectedIndividuals() : ($('#exportedIndividuals').val() == "" ? [] : getSelectedIndividuals([parseInt($('#exportedIndividuals').val())])));
exportedIndividualCount = indToExport == null ? indOpt.length : indToExport.length;
var keepExportOnServer = $('#keepExportOnServ').prop('checked');
-// if (!keepExportOnServer && $('#exportPanel div.individualRelated:visible').size() > 0) {
-// if (exportedIndividualCount * count > 1000000000) {
-// alert("The matrix you are about to export contains more than 1 billion genotypes and is too large to be downloaded directly. Please tick the 'Keep files on server' box.");
-// return;
-// }
-// }
var supportedTypes = $('#exportFormat').children().filter(':selected').data('type');
if (supportedTypes != null) {
@@ -1921,12 +1915,8 @@ https://doi.org/10.1093/gigascience/giz051
});
displayProcessProgress(2, "export_" + token, null, function() {
- if ($('#enableExportPush').prop('checked')) {
- let fileExtensions = $("#exportFormat option:selected").data('ext').split(";");
- if ($('#exportPanel input#exportedIndividualMetadataCheckBox').is(':checked') && "FLAPJACK" != $('#exportFormat').val() && "DARWIN" != $('#exportFormat').val() /* these two already have their own metadata file format*/)
- fileExtensions.push("tsv");
- showServerExportBox(fileExtensions, keepExportOnServer);
- }
+ if ($('#enableExportPush').prop('checked'))
+ showServerExportBox(keepExportOnServer);
else {
var link = document.createElement('a');
link.href = downloadURL;
diff --git a/src/main/webapp/js/common.js b/src/main/webapp/js/common.js
index 3b61c81c..2ac8a4d0 100644
--- a/src/main/webapp/js/common.js
+++ b/src/main/webapp/js/common.js
@@ -314,21 +314,21 @@ function grabNcbiTaxon(inputObj)
$(inputObj).val(taxonName);
}
-function showGalaxyPushButton()
-{
- var galaxyInstanceUrl = $("#galaxyInstanceURL").val().trim();
- if (galaxyInstanceUrl.startsWith("http")) {
- var fileURLs = "";
- for (key in archivedDataFiles)
- fileURLs += (fileURLs == "" ? "" : " ,") + "'" + archivedDataFiles[key] + "'";
- $('#galaxyPushButton').html('
Galaxy
');
- $("#galaxyPushButton").show();
- }
- else
- $("#galaxyPushButton").hide();
-}
-
-function showServerExportBox(exportFormatExtensions, keepExportOnServer)
+//function showGalaxyPushButton()
+//{
+// var galaxyInstanceUrl = $("#galaxyInstanceURL").val().trim();
+// if (galaxyInstanceUrl.startsWith("http")) {
+// var fileURLs = "";
+// for (key in archivedDataFiles)
+// fileURLs += (fileURLs == "" ? "" : " ,") + "'" + archivedDataFiles[key] + "'";
+// $('#galaxyPushButton').html(' Galaxy
');
+// $("#galaxyPushButton").show();
+// }
+// else
+// $("#galaxyPushButton").hide();
+//}
+
+function showServerExportBox(keepExportOnServer, exportFormatExtensions)
{
$("div#exportPanel").hide();
$("a#exportBoxToggleButton").removeClass("active");
@@ -346,10 +346,25 @@ function showServerExportBox(exportFormatExtensions, keepExportOnServer)
$('#serverExportBox').append("");
archivedDataFiles = new Array();
+
+ if (exportFormatExtensions == null) {
+ exportFormatExtensions = $("#exportFormat option:selected").data('ext').split(";");
+ if ($('#exportPanel input#exportedIndividualMetadataCheckBox').is(':checked') && "FLAPJACK" != $('#exportFormat').val() && "DARWIN" != $('#exportFormat').val() /* these two already have their own metadata file format*/)
+ exportFormatExtensions.push("tsv");
+ }
for (var key in exportFormatExtensions)
archivedDataFiles[exportFormatExtensions[key]] = location.origin + downloadURL.replace(new RegExp(/\.[^.]*$/), '.' + exportFormatExtensions[key]);
- showGalaxyPushButton();
+ var galaxyInstanceUrl = $("#galaxyInstanceURL").val().trim();
+ if (galaxyInstanceUrl.startsWith("http")) {
+ var fileURLs = "";
+ for (key in archivedDataFiles)
+ fileURLs += (fileURLs == "" ? "" : " ,") + "'" + archivedDataFiles[key] + "'";
+ $('#galaxyPushButton').html(' Galaxy
');
+ $("#galaxyPushButton").show();
+ }
+ else
+ $("#galaxyPushButton").hide();
if (onlineOutputTools != null)
for (var toolName in onlineOutputTools) {
@@ -381,7 +396,7 @@ function showServerExportBox(exportFormatExtensions, keepExportOnServer)
}
if (formatsForThisButton != "")
- $('#serverExportBox').append(' ')
+ $('#serverExportBox').append('
');
}
}
}
diff --git a/src/main/webapp/js/main.js b/src/main/webapp/js/main.js
index e3096285..b45f4520 100644
--- a/src/main/webapp/js/main.js
+++ b/src/main/webapp/js/main.js
@@ -1071,7 +1071,7 @@ function applyOutputToolConfig() {
$("#galaxyPushButton input").val("Send exported data to " + $("input#galaxyInstanceURL").val());
}
- showGalaxyPushButton();
+ showServerExportBox($('#keepExportOnServ').prop('checked'));
$("#applyOutputToolConfig").prop("disabled", "disabled");
}