changeset 2096:bf598599782a

Made old calculation results available for floodmaps. flys-artifacts/trunk@3644 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Wed, 11 Jan 2012 10:17:16 +0000
parents 8cb679d4ec49
children a18ec861b4a4
files flys-artifacts/ChangeLog flys-artifacts/doc/conf/meta-data.xml
diffstat 2 files changed, 43 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Tue Jan 10 11:50:01 2012 +0000
+++ b/flys-artifacts/ChangeLog	Wed Jan 11 10:17:16 2012 +0000
@@ -1,3 +1,8 @@
+2012-01-11  Ingo Weinzierl <ingo@intevation.de>
+
+	* doc/conf/meta-data.xml: Added the definition of old calculation results
+	  for floodmaps.
+
 2012-01-10  Ingo Weinzierl <ingo@intevation.de>
 
 	* src/main/java/de/intevation/flys/artifacts/model/WMSLayerFacet.java: Added
--- a/flys-artifacts/doc/conf/meta-data.xml	Tue Jan 10 11:50:01 2012 +0000
+++ b/flys-artifacts/doc/conf/meta-data.xml	Wed Jan 11 10:17:16 2012 +0000
@@ -874,6 +874,44 @@
           </waterlevels>
         </dc:if>
 
+        <dc:comment>
+          SHOW FLOODMAPS
+        </dc:comment>
+
+        <dc:if test="dc:contains($artifact-outs, 'floodmap')">
+          <floodmap>
+            <dc:elements>
+                <dc:context>
+                  <dc:statement>
+                    SELECT m.id AS a_id, m.state AS a_state, m.gid AS a_gid, m.creation AS a_creation
+                    FROM   master_artifacts m
+                    WHERE  m.collection_id = ${collection_id} AND m.gid &lt;&gt; CAST(${artifact-id} AS uuid)
+                    AND EXISTS (
+                        SELECT id FROM artifact_data ad WHERE ad.artifact_id = m.id AND k = 'river' AND v = ${river})
+                  </dc:statement>
+                  <dc:elements>
+                      <dc:context>
+                        <dc:statement>
+                          SELECT a.gid as aid, f.id AS fid, f.name AS facet_name, f.num AS facet_num, f.description as facet_description
+                          FROM outs as o, facets as f, artifacts as a
+                          WHERE f.name = 'floodmap.wsplgen' and f.out_id = o.id and o.artifact_id = ${a_id} and a.id = ${a_id}
+                        </dc:statement>
+                        <dc:elements>
+                          <dc:element name="${facet_name}">
+                            <dc:attribute name="description" value="${facet_description}"/>
+                            <dc:attribute name="factory"     value="winfo"/>
+                            <dc:attribute name="artifact-id" value="${aid}"/>
+                            <dc:attribute name="ids"         value="${aid}"/>
+                            <dc:attribute name="out"         value="floodmap"/>
+                          </dc:element>
+                        </dc:elements>
+                      </dc:context>
+                  </dc:elements>
+                </dc:context>
+            </dc:elements>
+          </floodmap>
+        </dc:if>
+
       </dc:context>
       </old_calculations>
 

http://dive4elements.wald.intevation.org