Mercurial > dive4elements > river
changeset 8079:1c57c9dc1661
Datacage config for new sediment load structures. Missing: some facets and everything down from the innermost macros for sediment load at measurement stations.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Fri, 08 Aug 2014 13:24:11 +0200 |
parents | a403dbdb9e81 |
children | 13c3d861db1d 3ae11daff343 |
files | artifacts/doc/conf/meta-data.xml gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.java gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.properties gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_de.properties gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_en.properties |
diffstat | 5 files changed, 171 insertions(+), 134 deletions(-) [+] |
line wrap: on
line diff
--- a/artifacts/doc/conf/meta-data.xml Thu Aug 07 20:03:44 2014 +0200 +++ b/artifacts/doc/conf/meta-data.xml Fri Aug 08 13:24:11 2014 +0200 @@ -1407,133 +1407,145 @@ </densities> </dc:macro> - <dc:macro name="one-load"> - <dc:for-each> - <dc:variable name="syear" type="string" expr="dc:date-format('yyyy', $year)"/> - <year description="{$syear}" - factory="sedimentyield" - target_out="{$out}" - info="{$description}" - ids="{$syid}" /> - </dc:for-each> + <dc:macro name="one-load_ls"> + <dc:variable name="syear" type="string" expr="dc:date-format('yyyy', $year)"/> + <year description="{$syear}" + factory="sedimentyield" + target_out="{$out}" + info="{$description}" + ids="{$syid}" /> </dc:macro> - <dc:macro name="epoch-load"> - <dc:for-each> - <dc:variable name="syear" type="string" expr="dc:date-format('yyyy', $startyear)"/> - <dc:variable name="eyear" type="string" expr="dc:date-format('yyyy', $endyear)"/> - <year description="{$syear}-{$eyear}" - factory="sedimentyield" - target_out="{$out}" - info="{$description}" - ids="{$syid}" /> - </dc:for-each> + <dc:macro name="epoch-load_ls"> + <dc:variable name="syear" type="string" expr="dc:date-format('yyyy', $startyear)"/> + <dc:variable name="eyear" type="string" expr="dc:date-format('yyyy', $endyear)"/> + <year description="{$syear}-{$eyear}" + factory="sedimentyield" + target_out="{$out}" + info="{$description}" + ids="{$syid}" /> </dc:macro> <dc:macro name="loads"> <dc:if test="dc:has-result()"> - <dc:filter expr="$fraction='sand'"> - <dc:if test="dc:has-result()"> - <sand> - <dc:macro-body/> - </sand> - </dc:if> - </dc:filter> - <dc:filter expr="$fraction='fine_middle'"> - <dc:if test="dc:has-result()"> - <fine_middle> - <dc:macro-body/> - </fine_middle> - </dc:if> - </dc:filter> - <dc:filter expr="$fraction='coarse'"> - <dc:if test="dc:has-result()"> - <coarse> - <dc:macro-body/> - </coarse> - </dc:if> - </dc:filter> - <dc:filter expr="$fraction='suspended_sediment'"> - <dc:if test="dc:has-result()"> - <susp_sediment> - <dc:macro-body/> - </susp_sediment> - </dc:if> - </dc:filter> - <dc:filter expr="$fraction='susp_sand'"> - <dc:if test="dc:has-result()"> - <susp_sand> - <dc:macro-body/> - </susp_sand> - </dc:if> - </dc:filter> - <dc:filter expr="$fraction='susp_sand_bed'"> - <dc:if test="dc:has-result()"> - <susp_sand_bed> - <dc:macro-body/> - </susp_sand_bed> - </dc:if> - </dc:filter> - <dc:filter expr="$fraction='total'"> - <dc:if test="dc:has-result()"> - <total_load> - <dc:macro-body/> - </total_load> - </dc:if> - </dc:filter> + <dc:group expr="$fraction"> + <dc:variable name="fraction_name" expr="concat('\${', dc:group-key(), '}')"/> + <fraction description="{$fraction_name}"> + <dc:for-each> + <dc:macro-body/> + </dc:for-each> + </fraction> + </dc:group> </dc:if> </dc:macro> - + <dc:macro name="yields"> <yields> - <dc:call-macro name="annotations_sediment_load_ls"/> - <years> - <dc:context> - <dc:statement> - SELECT DISTINCT - sy.id AS syid, - sy.description AS description, - ti.start_time AS year, - gf.name AS fraction - FROM sediment_load_ls sy - JOIN rivers r ON sy.river_id = r.id - JOIN sediment_load_ls_values syv ON sy.id = syv.sediment_load_ls_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, year DESC - </dc:statement> - <dc:call-macro name="loads"> - <dc:call-macro name="one-load"/> - </dc:call-macro> - </dc:context> - </years> - <epochs> - <dc:context> - <dc:statement> - SELECT DISTINCT - sy.id AS syid, - sy.description AS description, - ti.start_time AS startyear, - ti.stop_time AS endyear, - gf.name AS fraction - FROM sediment_load_ls sy - JOIN rivers r ON sy.river_id = r.id - JOIN sediment_load_ls_values syv ON sy.id = syv.sediment_load_ls_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 NOT NULL - AND syv.station BETWEEN ${fromkm} AND ${tokm} - ORDER BY fraction, startyear DESC, endyear DESC - </dc:statement> - <dc:call-macro name="loads"> - <dc:call-macro name="epoch-load"/> - </dc:call-macro> - </dc:context> - </epochs> + <dc:call-macro name="annotations_sediment_load_ls"/> + <measurement_stations> + <years> + <dc:context> + <dc:statement> + SELECT DISTINCT + sy.id AS syid, + sy.description AS description, + ti.start_time AS year, + gf.name AS fraction + FROM sediment_load sy + JOIN sediment_load_values syv + ON sy.id = syv.sediment_load_id + JOIN measurement_station ms + ON ms.id = syv.measurement_station_id + JOIN rivers r ON ms.river_id = r.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 ms.station BETWEEN ${fromkm} AND ${tokm} + ORDER BY fraction, year DESC + </dc:statement> + <dc:call-macro name="loads"> + <dc:call-macro name="one-load"/> + </dc:call-macro> + </dc:context> + </years> + <epochs> + <dc:context> + <dc:statement> + SELECT DISTINCT + sy.id AS syid, + sy.description AS description, + ti.start_time AS startyear, + ti.stop_time AS endyear, + gf.name AS fraction + FROM sediment_load sy + JOIN sediment_load_values syv + ON sy.id = syv.sediment_load_id + JOIN measurement_station ms + ON ms.id = syv.measurement_station_id + JOIN rivers r ON ms.river_id = r.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 NOT NULL + AND ms.station BETWEEN ${fromkm} AND ${tokm} + ORDER BY fraction, startyear DESC, endyear DESC + </dc:statement> + <dc:call-macro name="loads"> + <dc:call-macro name="epoch-load"/> + </dc:call-macro> + </dc:context> + </epochs> + </measurement_stations> + <sediment_load_ls> + <years> + <dc:context> + <dc:statement> + SELECT DISTINCT + sy.id AS syid, + sy.description AS description, + ti.start_time AS year, + gf.name AS fraction + FROM sediment_load_ls sy + JOIN rivers r ON sy.river_id = r.id + JOIN sediment_load_ls_values syv ON sy.id = syv.sediment_load_ls_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, year DESC + </dc:statement> + <dc:call-macro name="loads"> + <dc:call-macro name="one-load_ls"/> + </dc:call-macro> + </dc:context> + </years> + <epochs> + <dc:context> + <dc:statement> + SELECT DISTINCT + sy.id AS syid, + sy.description AS description, + ti.start_time AS startyear, + ti.stop_time AS endyear, + gf.name AS fraction + FROM sediment_load_ls sy + JOIN rivers r ON sy.river_id = r.id + JOIN sediment_load_ls_values syv ON sy.id = syv.sediment_load_ls_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 NOT NULL + AND syv.station BETWEEN ${fromkm} AND ${tokm} + ORDER BY fraction, startyear DESC, endyear DESC + </dc:statement> + <dc:call-macro name="loads"> + <dc:call-macro name="epoch-load_ls"/> + </dc:call-macro> + </dc:context> + </epochs> + </sediment_load_ls> </yields> </dc:macro>
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.java Thu Aug 07 20:03:44 2014 +0200 +++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.java Fri Aug 08 13:24:11 2014 +0200 @@ -980,19 +980,27 @@ String sediment_load(); - String sand(); + String sediment_load_ls(); + + String measurement_stations(); + + String coarse(); String fine_middle(); - String susp_sediment(); - - String coarse(); + String sand(); String susp_sand(); String susp_sand_bed(); - String total_load(); + String suspended_sediment(); + + String total(); + + String bed_load(); + + String suspended_load(); // Capabilities Information Panel
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.properties Thu Aug 07 20:03:44 2014 +0200 +++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants.properties Fri Aug 08 13:24:11 2014 +0200 @@ -520,14 +520,20 @@ years = years epochs = epochs densities = Sediment Densities + sediment_load = Sediment Load +sediment_load_ls = Longitudinal sections +measurement_stations = Measurement stations +coarse = Coarse +fine_middle = Fine Middle sand = Sand -fine_middle = Fine Middle -susp_sediment = Suspended Sediment -coarse = Coarse susp_sand = Suspended Sand susp_sand_bed = Suspended Sand (bed) -total_load = Total load +suspended_sediment = Suspended Sediment +total = Total load +bed_load = Bed load +suspended_load = Suspended load + # No translation for the pegelonline wms service layer names. gauge_points = Pegelpunkte (WSV) gauge_level = Aktueller Wasserstand (WSV)
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_de.properties Thu Aug 07 20:03:44 2014 +0200 +++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_de.properties Fri Aug 08 13:24:11 2014 +0200 @@ -525,14 +525,20 @@ years = Einzeljahre epochs = Epochen densities = Sedimentdichte + sediment_load = Sedimentfracht -sand = Geschiebe Sand -fine_middle = Geschiebe Fein Mittel Kies +sediment_load_ls = L\u00e4ngsschnitte +measurement_stations = Messstellen coarse = Geschiebe Grobkorn +fine_middle = Geschiebe Fein Mittel Kies +sand = Geschiebe Sand susp_sand = Susp. Sand -susp_sediment = Susp. Sediment susp_sand_bed = Bettb. Anteil susp. Sand -total_load = Gesamtfracht +suspended_sediment = Susp. Sediment +total = Gesamtfracht +bed_load = Geschiebefracht +suspended_load = Suspensionsfracht + gauge_points = Pegelmessstelle (WMS) gauge_level = Wasserstand (WMS) gauge_names = Pegelname (WMS)
--- a/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_en.properties Thu Aug 07 20:03:44 2014 +0200 +++ b/gwt-client/src/main/java/org/dive4elements/river/client/client/FLYSConstants_en.properties Fri Aug 08 13:24:11 2014 +0200 @@ -505,14 +505,19 @@ years = years epochs = epochs densities = Sediment Densities + sediment_load = Sediment Load +sediment_load_ls = Longitudinal sections +measurement_stations = Measurement stations +coarse = Coarse +fine_middle = Fine Middle sand = Sand -fine_middle = Fine Middle -susp_sediment = Suspended Sediment -coarse = Coarse susp_sand = Suspended Sand susp_sand_bed = Suspended Sand (bed) -total_load = Total load +suspended_sediment = Suspended Sediment +total = Total load +bed_load = Bed load +suspended_load = Suspended load startcolor = Colorrange start color endcolor = Colorrange end color