# HG changeset patch # User gernotbelger # Date 1534338601 -7200 # Node ID 55e3b1a8aa0679ccf53b0cb0789eb27910262ca6 # Parent 34cd4faf43f4321f541f67a9b40cd49cf2e8d468 salix pdf export column added diff -r 34cd4faf43f4 -r 55e3b1a8aa06 artifacts/doc/conf/jasper/templates/uinfo.salixline.jrxml --- a/artifacts/doc/conf/jasper/templates/uinfo.salixline.jrxml Wed Aug 15 14:34:23 2018 +0200 +++ b/artifacts/doc/conf/jasper/templates/uinfo.salixline.jrxml Wed Aug 15 15:10:01 2018 +0200 @@ -1,6 +1,6 @@ - + @@ -140,6 +140,12 @@ + + + + + + @@ -177,6 +183,17 @@ + + + + + + + + + + + diff -r 34cd4faf43f4 -r 55e3b1a8aa06 artifacts/src/main/java/org/dive4elements/river/artifacts/uinfo/salix/SalixLineCalculationResult.java --- a/artifacts/src/main/java/org/dive4elements/river/artifacts/uinfo/salix/SalixLineCalculationResult.java Wed Aug 15 14:34:23 2018 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/uinfo/salix/SalixLineCalculationResult.java Wed Aug 15 15:10:01 2018 +0200 @@ -113,7 +113,7 @@ exportContextPDF.addJRMetadata(source, "salix_delta_mw", UInfoResultType.salix_mw_mnw); for (int i = 1; i <= this.getScenarioCount(); i++) { - // TODO Spaltenueberschriften der Scenarios + // TODO Spaltenueberschriften der Scenarios (falls gefordert) } exportContextPDF.addJRMetadata(source, "gauge_header", GeneralResultType.gaugeLabel); } @@ -125,17 +125,19 @@ lines.add(context.formatRowValue(row, UInfoResultType.salixline)); lines.add(context.formatRowValue(row, UInfoResultType.salix_mw_mnw)); - final NumberFormat formatter = ((AbstractExportContext) context).getSalixScenFormatter(); - final List scenarios = (List) row.getValue(UInfoResultType.customMultiRowColSalixScenarios); - for (int i = 1; i <= this.getScenarioCount(); i++) { - if (i > scenarios.size()) - break; - if (scenarios.get(i - 1) != null) { - lines.add(scenarios.get(i - 1).getDeltaWFormatted()); - lines.add(scenarios.get(i - 1).getSalixValueFormatted(formatter)); - } else { - lines.add(""); - lines.add(""); + if (context instanceof ExportContextCSV) { + final NumberFormat formatter = ((AbstractExportContext) context).getSalixScenFormatter(); + final List scenarios = (List) row.getValue(UInfoResultType.customMultiRowColSalixScenarios); + for (int i = 1; i <= this.getScenarioCount(); i++) { + if (i > scenarios.size()) + break; + if (scenarios.get(i - 1) != null) { + lines.add(scenarios.get(i - 1).getDeltaWFormatted()); + lines.add(scenarios.get(i - 1).getSalixValueFormatted(formatter)); + } else { + lines.add(""); + lines.add(""); + } } } lines.add(context.formatRowValue(row, GeneralResultType.gaugeLabel));