diff flys-artifacts/doc/conf/meta-data.xml @ 5086:4f65d833680f dami

Merge Default onto Dami branch. Dami is now temporarily a public merge branch to fix problems created by the merge.
author Andre Heinecke <aheinecke@intevation.de>
date Mon, 25 Feb 2013 11:50:13 +0100
parents 065a78d65007
children 137ff80f0a01 86e79fbb8fa3 1ffd36a06065 e37b25628dd4
line wrap: on
line diff
--- a/flys-artifacts/doc/conf/meta-data.xml	Mon Feb 25 11:46:36 2013 +0100
+++ b/flys-artifacts/doc/conf/meta-data.xml	Mon Feb 25 11:50:13 2013 +0100
@@ -1,6 +1,19 @@
 <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
 <dc:template xmlns:dc="http://www.intevation.org/2011/Datacage">
 <datacage>
+<dc:macro name="SQL-wst_columns_statement">
+    <dc:statement>
+        SELECT wst_columns.id          AS prot_column_id,
+               wst_columns.name        AS prot_column_name,
+               wst_columns.position    AS prot_rel_pos,
+               wst_columns.description AS info,
+               wst_ranges.a            AS deffrom,
+               wst_ranges.b            AS defto
+        FROM wst_columns, wst_ranges
+        WHERE wst_columns.wst_id = ${prot_id} AND wst_ranges.wst_column_id = wst_columns.id
+        ORDER by wst_columns.position
+    </dc:statement>
+</dc:macro>
   <dc:macro name="load-system">
     <dc:context connection="system">
       <dc:statement>
@@ -24,20 +37,13 @@
                   <basedata>
                     <dc:attribute name="name" value="${prot_description}"/>
                     <dc:context>
-                      <dc:statement>
-                        SELECT id       AS prot_column_id,
-                               name     AS prot_column_name,
-                               position AS prot_rel_pos,
-                               description AS info
-                        FROM wst_columns WHERE wst_id = ${prot_id}
-                        ORDER by position
-                      </dc:statement>
+                      <dc:call-macro name="SQL-wst_columns_statement"/>
                       <dc:elements>
                         <column>
                           <dc:attribute name="name" value="${prot_column_name}"/>
                           <dc:attribute name="ids" value="base_data-wstv-${prot_rel_pos}-${prot_id}"/>
                           <dc:attribute name="factory" value="staticwkms"/>
-                          <dc:attribute name="info" value="${info}"/>
+                          <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                         </column>
                       </dc:elements>
                     </dc:context>
@@ -59,20 +65,13 @@
                   <basedata>
                     <dc:attribute name="name" value="${prot_description}"/>
                     <dc:context>
-                      <dc:statement>
-                        SELECT id       AS prot_column_id,
-                               name     AS prot_column_name,
-                               position AS prot_rel_pos,
-                               description AS info
-                        FROM wst_columns WHERE wst_id = ${prot_id}
-                        ORDER by position
-                      </dc:statement>
+                      <dc:call-macro name="SQL-wst_columns_statement"/>
                       <dc:elements>
                         <column>
                           <dc:attribute name="name" value="${prot_column_name}"/>
                           <dc:attribute name="ids" value="base_data-wstv-${prot_rel_pos}-${prot_id}"/>
                           <dc:attribute name="factory" value="wqinterpol"/>
-                          <dc:attribute name="info" value="${info}"/>
+                          <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                         </column>
                       </dc:elements>
                     </dc:context>
@@ -95,20 +94,13 @@
                   <additional>
                     <dc:attribute name="name" value="${prot_description}"/>
                     <dc:context>
-                      <dc:statement>
-                        SELECT id       AS prot_column_id,
-                               name     AS prot_column_name,
-                               position AS prot_rel_pos,
-                               description AS info
-                        FROM wst_columns WHERE wst_id = ${prot_id}
-                        ORDER by position
-                      </dc:statement>
+                      <dc:call-macro name="SQL-wst_columns_statement"/>
                       <dc:elements>
                         <column>
                           <dc:attribute name="name" value="${prot_column_name}"/>
                           <dc:attribute name="ids" value="additionalsmarks-wstv-${prot_rel_pos}-${prot_id}"/>
                           <dc:attribute name="factory" value="staticwkms"/>
-                          <dc:attribute name="info" value="${info}"/>
+                          <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                         </column>
                       </dc:elements>
                     </dc:context>
@@ -131,20 +123,13 @@
                   <additional>
                     <dc:attribute name="name" value="${prot_description}"/>
                     <dc:context>
-                      <dc:statement>
-                        SELECT id       AS prot_column_id,
-                               name     AS prot_column_name,
-                               position AS prot_rel_pos,
-                               description AS info
-                        FROM wst_columns WHERE wst_id = ${prot_id}
-                        ORDER by position
-                      </dc:statement>
+                      <dc:call-macro name="SQL-wst_columns_statement"/>
                       <dc:elements>
                         <column>
                           <dc:attribute name="name" value="${prot_column_name}"/>
                           <dc:attribute name="ids" value="additionals-wstv-${prot_rel_pos}-${prot_id}"/>
                           <dc:attribute name="factory" value="staticwkms"/>
-                          <dc:attribute name="info" value="${info}"/>
+                          <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                         </column>
                       </dc:elements>
                     </dc:context>
@@ -167,20 +152,13 @@
                   <relativepoint>
                     <dc:attribute name="name" value="${prot_description}"/>
                     <dc:context>
-                      <dc:statement>
-                        SELECT id       AS prot_column_id,
-                               name     AS prot_column_name,
-                               position AS prot_rel_pos,
-                               description AS info
-                        FROM wst_columns WHERE wst_id = ${prot_id}
-                        ORDER by position
-                      </dc:statement>
+                      <dc:call-macro name="SQL-wst_columns_statement"/>
                       <dc:elements>
                         <column>
                           <dc:attribute name="name" value="${prot_column_name}"/>
                           <dc:attribute name="ids" value="additionals-wstv-${prot_rel_pos}-${prot_id}"/>
                           <dc:attribute name="factory" value="staticwkms"/>
-                          <dc:attribute name="info" value="${info}"/>
+                          <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                         </column>
                       </dc:elements>
                     </dc:context>
@@ -203,20 +181,13 @@
                   <dc:attribute name="name" value="${prot_description}"/>
                   <!--dc:attribute name="ids" value="fixations-wstv-A-${prot_id}"/-->
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos,
-                             description AS info
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="fixations-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="wqinterpol"/>
-                        <dc:attribute name="info" value="${info}"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>
@@ -238,20 +209,13 @@
                 <fixation>
                   <dc:attribute name="name" value="${prot_description}"/>
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos,
-                             description AS info
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="fixations-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="wqinterpol"/>
-                        <dc:attribute name="info" value="${info}"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>
@@ -273,20 +237,13 @@
                 <fixation>
                   <dc:attribute name="name" value="${prot_description}"/>
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos,
-                             description AS info
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="fixations-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="staticwkms"/>
-                        <dc:attribute name="info" value="${info}"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>
@@ -308,20 +265,13 @@
                 <relativepoint>
                   <dc:attribute name="name" value="${prot_description}"/>
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos,
-                             description AS info
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="fixations-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="staticwkms"/>
-                        <dc:attribute name="info" value="${info}"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>
@@ -344,20 +294,13 @@
                   <official>
                     <dc:attribute name="name" value="${prot_description}"/>
                     <dc:context>
-                      <dc:statement>
-                        SELECT id       AS prot_column_id,
-                               name     AS prot_column_name,
-                               position AS prot_rel_pos,
-                               description AS info
-                        FROM wst_columns WHERE wst_id = ${prot_id}
-                        ORDER by position
-                      </dc:statement>
+                      <dc:call-macro name="SQL-wst_columns_statement"/>
                       <dc:elements>
                         <column>
                           <dc:attribute name="name" value="${prot_column_name}"/>
                           <dc:attribute name="ids" value="additionals-wstv-${prot_rel_pos}-${prot_id}"/>
                           <dc:attribute name="factory" value="staticwqkms"/>
-                          <dc:attribute name="info" value="${info}"/>
+                          <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                         </column>
                       </dc:elements>
                     </dc:context>
@@ -379,20 +322,13 @@
                 <relativepoint>
                   <dc:attribute name="name" value="${prot_description}"/>
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos,
-                             description AS info
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="heightmarks_points-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="staticwkms"/>
-                        <dc:attribute name="info" value="${info}"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>
@@ -414,20 +350,13 @@
                 <heightmark>
                   <dc:attribute name="name" value="${prot_description}"/>
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos,
-                             description AS info
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="heightmarks_points-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="staticwkms"/>
-                        <dc:attribute name="info" value="${info}"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>
@@ -449,20 +378,13 @@
                 <heightmark>
                   <dc:attribute name="name" value="${prot_description}"/>
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos,
-                             description AS info
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="heightmarks_annotations-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="wqinterpol"/>
-                        <dc:attribute name="info" value="${info}"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>
@@ -488,20 +410,13 @@
                   <dc:attribute name="factory" value="staticwkms"/>
                   <columns>
                     <dc:context>
-                      <dc:statement>
-                        SELECT id       AS prot_column_id,
-                               name     AS prot_column_name,
-                               position AS prot_rel_pos,
-                               description AS info
-                        FROM wst_columns WHERE wst_id = ${prot_id}
-                        ORDER by position
-                      </dc:statement>
+                      <dc:call-macro name="SQL-wst_columns_statement"/>
                       <dc:elements>
                         <column>
                           <dc:attribute name="name" value="${prot_column_name}"/>
                           <dc:attribute name="ids" value="flood_protection-wstv-${prot_rel_pos}-${prot_id}"/>
                           <dc:attribute name="factory" value="staticwkms"/>
-                          <dc:attribute name="info" value="${info}"/>
+                          <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                         </column>
                       </dc:elements>
                     </dc:context>
@@ -527,18 +442,13 @@
                   <dc:attribute name="db-id" value="${prot_id}"/>
                   <dc:attribute name="factory" value="staticwkms"/>
                   <dc:context>
-                    <dc:statement>
-                      SELECT id       AS prot_column_id,
-                             name     AS prot_column_name,
-                             position AS prot_rel_pos
-                      FROM wst_columns WHERE wst_id = ${prot_id}
-                      ORDER by position
-                    </dc:statement>
+                    <dc:call-macro name="SQL-wst_columns_statement"/>
                     <dc:elements>
                       <column>
                         <dc:attribute name="name" value="${prot_column_name}"/>
                         <dc:attribute name="ids" value="flood_protection-wstv-${prot_rel_pos}-${prot_id}"/>
                         <dc:attribute name="factory" value="staticwkms"/>
+                        <dc:attribute name="info" value="${info} [km ${deffrom} - ${defto}]"/>
                       </column>
                     </dc:elements>
                   </dc:context>

http://dive4elements.wald.intevation.org