# HG changeset patch # User "Tom Gottfried " # Date 1411483547 -7200 # Node ID e3a8aa6eee3256a54b6f212d1306a2d5d68baab8 # Parent 4acf7cff7355f58cb6f0264cc545709d59910f20 Make SQ-relations loadable in WQ-diagrams. diff -r 4acf7cff7355 -r e3a8aa6eee32 artifacts/doc/conf/generators/discharge-diagram-defaults.xml --- a/artifacts/doc/conf/generators/discharge-diagram-defaults.xml Tue Sep 23 15:07:39 2014 +0200 +++ b/artifacts/doc/conf/generators/discharge-diagram-defaults.xml Tue Sep 23 16:45:47 2014 +0200 @@ -1,6 +1,7 @@ + @@ -8,4 +9,5 @@ + diff -r 4acf7cff7355 -r e3a8aa6eee32 artifacts/src/main/java/org/dive4elements/river/artifacts/access/RangeAccess.java --- a/artifacts/src/main/java/org/dive4elements/river/artifacts/access/RangeAccess.java Tue Sep 23 15:07:39 2014 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/access/RangeAccess.java Tue Sep 23 16:45:47 2014 +0200 @@ -133,7 +133,7 @@ } if (from == null) { - log.warn("No 'from' found. assume max of river."); + log.warn("No 'from' found. Assume min of river."); return getRiver().determineMinMaxDistance()[0]; } @@ -152,7 +152,7 @@ } if (to == null) { - log.warn("No 'to' found. assume max of river."); + log.warn("No 'to' found. Assume max of river."); return getRiver().determineMinMaxDistance()[1]; } diff -r 4acf7cff7355 -r e3a8aa6eee32 artifacts/src/main/java/org/dive4elements/river/exports/injector/ComputedDischargeInjector.java --- a/artifacts/src/main/java/org/dive4elements/river/exports/injector/ComputedDischargeInjector.java Tue Sep 23 15:07:39 2014 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/exports/injector/ComputedDischargeInjector.java Tue Sep 23 16:45:47 2014 +0200 @@ -28,7 +28,9 @@ Document doc ) { RangeAccess access = new RangeAccess((D4EArtifact)artifact); - double km = access.getFrom(); - ctx.putContextValue(CURRENT_KM, km); + if (access.hasFrom()) { + double km = access.getFrom(); + ctx.putContextValue(CURRENT_KM, km); + } } }