From 88a42abc9c89a1d87c1361df1dff6070e75725e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Meier?= Date: Mon, 21 Oct 2024 16:13:17 +0200 Subject: [PATCH] Partially merge changes from master. --- MetFragCommandLine/pom.xml | 2 +- MetFragLib/pom.xml | 2 +- MetFragR/pom.xml | 2 +- MetFragRest/pom.xml | 2 +- MetFragTools/pom.xml | 2 +- MetFragWeb/pom.xml | 6 +----- .../metfragweb/controller/MetFragWebBean.java | 17 ++++++++++++++--- pom.xml | 16 ++++++++-------- 8 files changed, 28 insertions(+), 21 deletions(-) diff --git a/MetFragCommandLine/pom.xml b/MetFragCommandLine/pom.xml index 8831585..9529e3b 100644 --- a/MetFragCommandLine/pom.xml +++ b/MetFragCommandLine/pom.xml @@ -6,7 +6,7 @@ de.ipbhalle.metfrag MetFrag - 2.5.0 + 2.5.1 de.ipbhalle.metfrag.commandline MetFragCommandLine diff --git a/MetFragLib/pom.xml b/MetFragLib/pom.xml index 0df64bd..9f6df5b 100644 --- a/MetFragLib/pom.xml +++ b/MetFragLib/pom.xml @@ -4,7 +4,7 @@ de.ipbhalle.metfrag MetFrag - 2.5.0 + 2.5.1 jar de.ipbhalle.metfraglib diff --git a/MetFragR/pom.xml b/MetFragR/pom.xml index 6be072c..c452fd7 100644 --- a/MetFragR/pom.xml +++ b/MetFragR/pom.xml @@ -4,7 +4,7 @@ de.ipbhalle.metfrag MetFrag - 2.5.0 + 2.5.1 de.ipbhalle.metfrag.r MetFragR diff --git a/MetFragRest/pom.xml b/MetFragRest/pom.xml index 2f6acf0..24d2ca0 100644 --- a/MetFragRest/pom.xml +++ b/MetFragRest/pom.xml @@ -4,7 +4,7 @@ de.ipbhalle.metfrag MetFrag - 2.5.0 + 2.5.1 de.ipbhalle.metfrag.metfragrest MetFragRest diff --git a/MetFragTools/pom.xml b/MetFragTools/pom.xml index df1a326..172fd66 100644 --- a/MetFragTools/pom.xml +++ b/MetFragTools/pom.xml @@ -4,7 +4,7 @@ de.ipbhalle.metfrag MetFrag - 2.5.0 + 2.5.1 de.ipbhalle.metfrag.tools MetFragTools diff --git a/MetFragWeb/pom.xml b/MetFragWeb/pom.xml index bbf9e3b..5ce7006 100644 --- a/MetFragWeb/pom.xml +++ b/MetFragWeb/pom.xml @@ -6,7 +6,7 @@ de.ipbhalle.metfrag MetFrag - 2.5.0 + 2.5.1 de.ipbhalle.metfragweb MetFragWeb @@ -54,10 +54,6 @@ org.apache.commons commons-email - - - - org.primefaces primefaces diff --git a/MetFragWeb/src/main/java/de/ipbhalle/metfragweb/controller/MetFragWebBean.java b/MetFragWeb/src/main/java/de/ipbhalle/metfragweb/controller/MetFragWebBean.java index c993401..1fa12f1 100644 --- a/MetFragWeb/src/main/java/de/ipbhalle/metfragweb/controller/MetFragWebBean.java +++ b/MetFragWeb/src/main/java/de/ipbhalle/metfragweb/controller/MetFragWebBean.java @@ -36,6 +36,8 @@ import org.primefaces.model.chart.LineChartModel; import org.primefaces.model.chart.LineChartSeries; +import org.primefaces.model.DefaultStreamedContent.Builder; + import de.ipbhalle.metfraglib.additionals.MathTools; import de.ipbhalle.metfraglib.exceptions.AtomTypeNotKnownFromInputListException; import de.ipbhalle.metfraglib.imagegenerator.HighlightSubStructureImageGenerator; @@ -76,7 +78,7 @@ @SessionScoped public class MetFragWebBean { - private final String version = "v2.5.0"; + private final String version = "v2.5.1"; /* * combines all the settings */ @@ -2014,7 +2016,11 @@ public org.primefaces.model.StreamedContent getDownloadParameters() { try { resource = this.beanSettingsContainer.getUserOutputDataHandler().getDownloadParameters(this.errorMessages, pathToProperties); } catch(Exception e) { - resource = DefaultStreamedContent.builder().contentType("application/zip").name("MetFragWeb_Parameters.zip").stream(() -> System.in).build(); + resource = DefaultStreamedContent.builder() + .name("MetFragWeb_Parameters.zip") + .contentType("application/zip") + .stream(() -> System.in) + .build(); } return resource; } @@ -2703,7 +2709,12 @@ public void closeScoresView() { * @return */ public org.primefaces.model.StreamedContent generateCandidateDownloadFile() { - org.primefaces.model.StreamedContent resource = DefaultStreamedContent.builder().contentType("application/vnd.ms-excel").name("MetFragWeb_Candidate.xls").stream(() -> System.in).build(); + org.primefaces.model.StreamedContent resource = DefaultStreamedContent.builder() + .name("MetFragWeb_Candidate.xls") + .contentType("application/vnd.ms-excel") + .stream(() -> System.in) + .build(); + try { resource = this.beanSettingsContainer.getUserOutputDataHandler().generatedCandidateDownloadFile(this.currentScoreCandidate, this.beanSettingsContainer.getMetFragSettings()); } catch (Exception e1) { diff --git a/pom.xml b/pom.xml index 9cfd1d9..1e173ef 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ 4.0.0 de.ipbhalle.metfrag MetFrag - 2.5.0 + 2.5.1 pom MetFrag @@ -24,7 +24,7 @@ de.ipbhalle.metfraglib MetFragLib - 2.5.0 + 2.5.1 junit @@ -108,18 +108,18 @@ org.omnifaces omnifaces - 4.0 + 3.13 org.apache.commons commons-email 1.5 - - - - - + + commons-fileupload + commons-fileupload + 1.5 + org.primefaces primefaces