[PATCH] issue1435: DC layout for sediment-loads more the way its requested

Wald Commits scm-commit at wald.intevation.org
Wed Oct 2 11:33:30 CEST 2013


# HG changeset patch
# User Felix Wolfsteller <felix.wolfsteller at intevation.de>
# Date 1380707063 -7200
# Node ID 2c26a7217732e71b3e599ab0dd820d876f2d0623
# Parent  7a6cb5b34bfc94f8bacca025f7fe9d15cceb79a4
issue1435: DC layout for sediment-loads more the way its requested.

diff -r 7a6cb5b34bfc -r 2c26a7217732 artifacts/doc/conf/meta-data.xml
--- a/artifacts/doc/conf/meta-data.xml	Tue Oct 01 10:06:11 2013 +0200
+++ b/artifacts/doc/conf/meta-data.xml	Wed Oct 02 11:44:23 2013 +0200
@@ -1268,21 +1268,25 @@
             SELECT DISTINCT
                 sy.id AS syid,
                 sy.description AS description,
-                ti.start_time AS year
+                ti.start_time  AS year,
+                gf.name        AS fraction
             FROM     sediment_yield sy
                 JOIN rivers r ON sy.river_id = r.id
                 JOIN sediment_yield_values syv ON sy.id = syv.sediment_yield_id
                 JOIN time_intervals ti ON sy.time_interval_id = ti.id
+                JOIN grain_fraction gf ON gf.id = sy.grain_fraction_id
             WHERE   r.id = ${river_id}
                 AND ti.stop_time IS NULL
                 AND syv.station BETWEEN ${fromkm} AND ${tokm}
+            ORDER BY fraction
         </dc:statement>
         <dc:if test="dc:has-result()">
           <dc:for-each>
-            <year description="{$description}"
+            <dc:variable name="syear" type="string" expr="dc:date-format('yyyy', $year)"/>
+            <year description="{$syear} - {$description}"
                    factory="sedimentyield"
                    target_out="{$out}"
-                   info="infome"
+                   info="{$syear}-{$fraction}"
                   ids="{$syid}" />
           </dc:for-each>
         </dc:if>


More information about the Dive4elements-commits mailing list