diff flys-artifacts/doc/conf/meta-data.xml @ 2580:3d240200364c

Improved the datacage configuration to serve floodmaps. flys-artifacts/trunk@4128 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 08 Mar 2012 13:06:11 +0000
parents 700f28bfd7ef
children 631dabad9b48
line wrap: on
line diff
--- a/flys-artifacts/doc/conf/meta-data.xml	Mon Mar 05 10:53:42 2012 +0000
+++ b/flys-artifacts/doc/conf/meta-data.xml	Thu Mar 08 13:06:11 2012 +0000
@@ -701,6 +701,84 @@
                   </dc:elements>
                 </dc:context>
               </dc:macro>
+              <dc:macro name="flood-map-uesk">
+                <uesk>
+                  <calculations>
+                    <current>
+                      <dc:context>
+                        <dc:statement>
+                            SELECT count(*) as uesg_exist, name as name
+                            FROM floodmaps
+                            WHERE river_id = ${river_id} AND kind = 111
+                            GROUP BY name, kind
+                        </dc:statement>
+                        <dc:elements>
+                          <dc:if test="$uesg_exist>0">
+                            <bfg>
+                              <dc:attribute name="factory" value="wmsfloodmapsfactory"/>
+                              <dc:attribute name="ids" value="${river_id}_${name}"/>
+                              <dc:attribute name="name" value="${name}"/>
+                            </bfg>
+                          </dc:if>
+                        </dc:elements>
+                      </dc:context>
+                      <dc:context>
+                        <dc:statement>
+                            SELECT count(*) as uesg_exist, name as name
+                            FROM floodmaps
+                            WHERE river_id = ${river_id} AND kind = 112
+                            GROUP BY name, kind
+                        </dc:statement>
+                        <dc:elements>
+                          <dc:if test="$uesg_exist>0">
+                            <land>
+                              <dc:attribute name="factory" value="wmsfloodmapsfactory"/>
+                              <dc:attribute name="ids" value="${river_id}_${name}"/>
+                              <dc:attribute name="name" value="${name}"/>
+                            </land>
+                          </dc:if>
+                        </dc:elements>
+                      </dc:context>
+                    </current>
+                    <potentiel>
+                      <dc:context>
+                        <dc:statement>
+                            SELECT count(*) as uesg_exist, name as name
+                            FROM floodmaps
+                            WHERE river_id = ${river_id} AND kind = 121
+                            GROUP BY name, kind
+                        </dc:statement>
+                        <dc:elements>
+                          <dc:if test="$uesg_exist>0">
+                            <bfg>
+                              <dc:attribute name="factory" value="wmsfloodmapsfactory"/>
+                              <dc:attribute name="ids" value="${river_id}_${name}"/>
+                              <dc:attribute name="name" value="${name}"/>
+                            </bfg>
+                          </dc:if>
+                        </dc:elements>
+                      </dc:context>
+                      <dc:context>
+                        <dc:statement>
+                            SELECT count(*) as uesg_exist, name as name
+                            FROM floodmaps
+                            WHERE river_id = ${river_id} AND kind = 122
+                            GROUP BY name, kind
+                        </dc:statement>
+                        <dc:elements>
+                          <dc:if test="$uesg_exist>0">
+                            <land>
+                              <dc:attribute name="factory" value="wmsfloodmapsfactory"/>
+                              <dc:attribute name="ids" value="${river_id}_${name}"/>
+                              <dc:attribute name="name" value="${name}"/>
+                            </land>
+                          </dc:if>
+                        </dc:elements>
+                      </dc:context>
+                    </potentiel>
+                  </calculations>
+                </uesk>
+              </dc:macro>
               <dc:macro name="flood-map-complete">
                   <kilometrage>
                       <riveraxis>
@@ -715,6 +793,7 @@
                     <dc:call-macro name="flood-map-lines"/>
                     <dc:call-macro name="flood-map-buildings"/>
                     <dc:call-macro name="flood-map-fixpoints"/>
+                    <dc:call-macro name="flood-map-uesk"/>
                   </kilometrage>
                   <rastermap>
                       <background>

http://dive4elements.wald.intevation.org