changeset 7576:4f69ebe580e1

issue1613: In DC, also show the 'diff' facets, define former calc. for hist. W/Q out.
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Mon, 18 Nov 2013 12:30:36 +0100
parents 8fd314253839
children b8b185911eb4
files artifacts/doc/conf/meta-data.xml
diffstat 1 files changed, 27 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/artifacts/doc/conf/meta-data.xml	Mon Nov 18 12:22:22 2013 +0100
+++ b/artifacts/doc/conf/meta-data.xml	Mon Nov 18 12:30:36 2013 +0100
@@ -397,6 +397,9 @@
                     <dc:when test="$out = 'historical_discharge'">
                       <dc:call-macro name="historical-discharge-user"/>
                     </dc:when>
+                    <dc:when test="$out = 'historical_discharge_wq'">
+                      <dc:call-macro name="historical-discharge-wq-user"/>
+                    </dc:when>
                     <dc:when test="starts-with($out, 'sq_relation')">
                       <dc:call-macro name="sqrelations_user"/>
                     </dc:when>
@@ -412,7 +415,30 @@
     <!-- 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:filter expr="$out = 'historical_discharge' and starts-with($facet_name, 'historical_discharge.historical')">
+        <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="historical-discharge-wq-user">
+      <dc:filter expr="$out = 'historical_discharge_wq' and starts-with($facet_name, 'historical_discharge.wq')">
         <dc:if test="dc:has-result()">
           <historical_discharges>
             <dc:call-macro name="collection-group">

http://dive4elements.wald.intevation.org