changeset 7575:8fd314253839

issue1631: Allow loading of some former historical-discharge facets.
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Mon, 18 Nov 2013 12:22:22 +0100
parents 6f6a63ab3ced
children 4f69ebe580e1
files artifacts/doc/conf/meta-data.xml
diffstat 1 files changed, 26 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/artifacts/doc/conf/meta-data.xml	Thu Nov 14 12:02:26 2013 +0100
+++ b/artifacts/doc/conf/meta-data.xml	Mon Nov 18 12:22:22 2013 +0100
@@ -394,6 +394,9 @@
                     <dc:when test="$out = 'bed_difference_epoch'">
                       <dc:call-macro name="longitudinal-section-user-prototype"/>
                     </dc:when>
+                    <dc:when test="$out = 'historical_discharge'">
+                      <dc:call-macro name="historical-discharge-user"/>
+                    </dc:when>
                     <dc:when test="starts-with($out, 'sq_relation')">
                       <dc:call-macro name="sqrelations_user"/>
                     </dc:when>
@@ -408,6 +411,29 @@
 
     <!-- Macros to load user data -->
 
+    <dc:macro name="historical-discharge-user">
+      <dc:filter expr="$out = 'historical_discharge' and ($facet_name = 'historical_discharge.historicalq' or $facet_name = 'historical_discharge.historicalw')">
+        <dc:if test="dc:has-result()">
+          <historical_discharges>
+            <dc:call-macro name="collection-group">
+              <discharges description="{dc:group-key()}">
+                <dc:for-each>
+                  <dc:element name="${facet_name}">
+                    <dc:attribute name="description" value="${facet_description}"/>
+                    <dc:attribute name="factory" value="winfo"/>
+                    <dc:attribute name="target_out" value="${out}"/>
+                    <dc:attribute name="artifact-id" value="${a_gid}"/>
+                    <dc:attribute name="ids" value="${facet_num}"/>
+                    <dc:attribute name="out" value="historical_discharge"/>
+                  </dc:element>
+                </dc:for-each>
+              </discharges>
+            </dc:call-macro>
+          </historical_discharges>
+        </dc:if>
+      </dc:filter>
+    </dc:macro>
+
     <dc:macro name="differences">
       <dc:filter expr="$facet_name = 'w_differences'">
         <dc:if test="dc:has-result()">

http://dive4elements.wald.intevation.org