comparison artifacts/doc/conf/meta-data.xml @ 9233:03427b89ba62

Configured 'year' attributes on bed heights,certain waterlevels and fixation results; this is used in the intelligent datacage selection for waterlevels-soundings
author gernotbelger
date Fri, 06 Jul 2018 13:10:31 +0200
parents 1614cb14308f
children c2a0028bfa9f
comparison
equal deleted inserted replaced
9232:5030c46d8cb4 9233:03427b89ba62
644 <dc:attribute name="ids" value="${facet_num}" /> 644 <dc:attribute name="ids" value="${facet_num}" />
645 <dc:attribute name="factory" value="fixanalysis" /> 645 <dc:attribute name="factory" value="fixanalysis" />
646 <dc:attribute name="target_out" value="${out}" /> 646 <dc:attribute name="target_out" value="${out}" />
647 <dc:attribute name="artifact-id" value="${a_gid}" /> 647 <dc:attribute name="artifact-id" value="${a_gid}" />
648 <dc:attribute name="out" value="longitudinal_section" /> 648 <dc:attribute name="out" value="longitudinal_section" />
649
650 <dc:variable name="fixAnalysisYear" expr="dc:fix_analysis_year($a_gid)" />
651 <dc:attribute name="year" value="${fixAnalysisYear}" />
649 </dc:element> 652 </dc:element>
650 </dc:for-each> 653 </dc:for-each>
651 </waterlevels> 654 </waterlevels>
652 </dc:call-macro> 655 </dc:call-macro>
653 </waterlevels_fix_vollmer> 656 </waterlevels_fix_vollmer>
1306 <dc:macro name="basedata_1_additionals_macro"> 1309 <dc:macro name="basedata_1_additionals_macro">
1307 <dc:filter expr="$kind=1"> 1310 <dc:filter expr="$kind=1">
1308 <dc:if test="dc:has-result()"> 1311 <dc:if test="dc:has-result()">
1309 <additionals> 1312 <additionals>
1310 <dc:group expr="dc:replace($wst_description, 'Zus.Längsschnitte/', '')"> 1313 <dc:group expr="dc:replace($wst_description, 'Zus.Längsschnitte/', '')">
1311 <additional name="{dc:group-key()}"> 1314 <additional name="{dc:group-key()}" description="{dc:group-key()}">
1312 <dc:for-each> 1315 <dc:for-each>
1313 <dc:macro-body /> 1316 <dc:macro-body />
1314 </dc:for-each> 1317 </dc:for-each>
1315 </additional> 1318 </additional>
1316 </dc:group> 1319 </dc:group>
1328 <dc:macro name="basedata_1_additionals-sinfo-with-q_macro"> 1331 <dc:macro name="basedata_1_additionals-sinfo-with-q_macro">
1329 <dc:filter expr="$kind=1 and $sinfo_selection='Q'"> 1332 <dc:filter expr="$kind=1 and $sinfo_selection='Q'">
1330 <dc:if test="dc:has-result()"> 1333 <dc:if test="dc:has-result()">
1331 <sinfo_additional_ls_withQ> 1334 <sinfo_additional_ls_withQ>
1332 <dc:group expr="dc:replace($wst_description, 'Zus.Längsschnitte/', '')"> 1335 <dc:group expr="dc:replace($wst_description, 'Zus.Längsschnitte/', '')">
1333 <additional name="{dc:group-key()}"> 1336 <additional name="{dc:group-key()}" description="{dc:group-key()}">
1334 <dc:for-each> 1337 <dc:for-each>
1335 <dc:macro-body /> 1338 <dc:macro-body />
1336 </dc:for-each> 1339 </dc:for-each>
1337 </additional> 1340 </additional>
1338 </dc:group> 1341 </dc:group>
1341 </dc:filter> 1344 </dc:filter>
1342 </dc:macro> 1345 </dc:macro>
1343 1346
1344 <dc:macro name="basedata_1_additionals-sinfo-with-q"> 1347 <dc:macro name="basedata_1_additionals-sinfo-with-q">
1345 <dc:call-macro name="basedata_1_additionals-sinfo-with-q_macro"> 1348 <dc:call-macro name="basedata_1_additionals-sinfo-with-q_macro">
1346 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" /> 1349 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" year="{dc:date-format('yyyy', $start_time)}" />
1347 </dc:call-macro> 1350 </dc:call-macro>
1348 </dc:macro> 1351 </dc:macro>
1349 1352
1350 <dc:macro name="basedata_1_additionals-sinfo-without-q_macro"> 1353 <dc:macro name="basedata_1_additionals-sinfo-without-q_macro">
1351 <dc:filter expr="$kind=1 and $sinfo_selection='W'"> 1354 <dc:filter expr="$kind=1 and $sinfo_selection='W'">
1352 <dc:if test="dc:has-result()"> 1355 <dc:if test="dc:has-result()">
1353 <sinfo_additional_ls_withoutQ> 1356 <sinfo_additional_ls_withoutQ>
1354 <dc:group expr="dc:replace($wst_description, 'Zus.Längsschnitte/', '')"> 1357 <dc:group expr="dc:replace($wst_description, 'Zus.Längsschnitte/', '')">
1355 <additional name="{dc:group-key()}"> 1358 <additional name="{dc:group-key()}" description="{dc:group-key()}">
1356 <dc:for-each> 1359 <dc:for-each>
1357 <dc:macro-body /> 1360 <dc:macro-body />
1358 </dc:for-each> 1361 </dc:for-each>
1359 </additional> 1362 </additional>
1360 </dc:group> 1363 </dc:group>
1363 </dc:filter> 1366 </dc:filter>
1364 </dc:macro> 1367 </dc:macro>
1365 1368
1366 <dc:macro name="basedata_1_additionals-sinfo-without-q"> 1369 <dc:macro name="basedata_1_additionals-sinfo-without-q">
1367 <dc:call-macro name="basedata_1_additionals-sinfo-without-q_macro"> 1370 <dc:call-macro name="basedata_1_additionals-sinfo-without-q_macro">
1368 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" /> 1371 <dc:variable name="start_year" expr="dc:date-format('yyyy', $start_time)" />
1372 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" year="{dc:date-format('yyyy', $start_time)}" />
1369 </dc:call-macro> 1373 </dc:call-macro>
1370 </dc:macro> 1374 </dc:macro>
1371 1375
1372 <dc:macro name="basedata_1_additionals_wq"> 1376 <dc:macro name="basedata_1_additionals_wq">
1373 <dc:call-macro name="basedata_1_additionals_macro"> 1377 <dc:call-macro name="basedata_1_additionals_macro">
1398 </dc:filter> 1402 </dc:filter>
1399 </dc:macro> 1403 </dc:macro>
1400 1404
1401 <dc:macro name="basedata_2_fixations"> 1405 <dc:macro name="basedata_2_fixations">
1402 <dc:call-macro name="fixings-macro"> 1406 <dc:call-macro name="fixings-macro">
1403 <column name="{$wst_column_name}" ids="fixations-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" /> 1407 <dc:variable name="start_year" expr="dc:date-format('yyyy', $start_time)" />
1408 <column name="{$wst_column_name}" ids="fixations-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" year="{dc:date-format('yyyy', $start_time)}" />
1404 </dc:call-macro> 1409 </dc:call-macro>
1405 </dc:macro> 1410 </dc:macro>
1406 1411
1407 <dc:macro name="basedata_2_fixations_wq"> 1412 <dc:macro name="basedata_2_fixations_wq">
1408 <dc:call-macro name="fixings-macro"> 1413 <dc:call-macro name="fixings-macro">
1433 </dc:filter> 1438 </dc:filter>
1434 </dc:macro> 1439 </dc:macro>
1435 1440
1436 <dc:macro name="basedata_3_officials"> 1441 <dc:macro name="basedata_3_officials">
1437 <dc:call-macro name="basedata_3_macro"> 1442 <dc:call-macro name="basedata_3_macro">
1438 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" /> 1443 <dc:variable name="start_year" expr="dc:date-format('yyyy', $start_time)" />
1444 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" year="{dc:date-format('yyyy', $start_time)}" />
1439 </dc:call-macro> 1445 </dc:call-macro>
1440 </dc:macro> 1446 </dc:macro>
1441 1447
1442 <dc:macro name="basedata_3_officials_wq"> 1448 <dc:macro name="basedata_3_officials_wq">
1443 <dc:call-macro name="basedata_3_macro"> 1449 <dc:call-macro name="basedata_3_macro">
1521 <dc:if test="dc:has-result()"> 1527 <dc:if test="dc:has-result()">
1522 <delta_w> 1528 <delta_w>
1523 <delta_w_cm> 1529 <delta_w_cm>
1524 <dc:filter expr="contains($wst_description, 'cm.csv')"> 1530 <dc:filter expr="contains($wst_description, 'cm.csv')">
1525 <dc:group expr="dc:replace($wst_description, 'CSV/', '')"> 1531 <dc:group expr="dc:replace($wst_description, 'CSV/', '')">
1526 <relativepoint name="{dc:group-key()}"> 1532 <relativepoint name="{dc:group-key()}" description="{dc:group-key()}">
1527 <dc:for-each> 1533 <dc:for-each>
1528 <column name="{$wst_column_name}" ids="delta_w-wstv-{$wst_column_position}-{$wst_id}" factory="staticwkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" /> 1534 <column name="{$wst_column_name}" ids="delta_w-wstv-{$wst_column_position}-{$wst_id}" factory="staticwkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" />
1529 </dc:for-each> 1535 </dc:for-each>
1530 </relativepoint> 1536 </relativepoint>
1531 </dc:group> 1537 </dc:group>
1532 </dc:filter> 1538 </dc:filter>
1533 </delta_w_cm> 1539 </delta_w_cm>
1534 <delta_w_cma> 1540 <delta_w_cma>
1535 <dc:filter expr="contains($wst_description, 'cm-a.csv')"> 1541 <dc:filter expr="contains($wst_description, 'cm-a.csv')">
1536 <dc:group expr="dc:replace($wst_description, 'CSV/', '')"> 1542 <dc:group expr="dc:replace($wst_description, 'CSV/', '')">
1537 <relativepoint name="{dc:group-key()}"> 1543 <relativepoint name="{dc:group-key()}" description="{dc:group-key()}">
1538 <dc:for-each> 1544 <dc:for-each>
1539 <column name="{$wst_column_name}" ids="delta_w_cma-wstv-{$wst_column_position}-{$wst_id}" factory="staticwkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" /> 1545 <column name="{$wst_column_name}" ids="delta_w_cma-wstv-{$wst_column_position}-{$wst_id}" factory="staticwkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" />
1540 </dc:for-each> 1546 </dc:for-each>
1541 </relativepoint> 1547 </relativepoint>
1542 </dc:group> 1548 </dc:group>
1551 <dc:macro name="basedata_7_macro"> 1557 <dc:macro name="basedata_7_macro">
1552 <dc:filter expr="$kind=7"> 1558 <dc:filter expr="$kind=7">
1553 <dc:if test="dc:has-result()"> 1559 <dc:if test="dc:has-result()">
1554 <wlevel> 1560 <wlevel>
1555 <dc:group expr="dc:replace($wst_description, 'CSV/', '')"> 1561 <dc:group expr="dc:replace($wst_description, 'CSV/', '')">
1556 <relativepoint name="{dc:group-key()}"> 1562 <relativepoint name="{dc:group-key()}" description="{dc:group-key()}">
1557 <dc:for-each> 1563 <dc:for-each>
1558 <dc:macro-body /> 1564 <dc:macro-body />
1559 </dc:for-each> 1565 </dc:for-each>
1560 </relativepoint> 1566 </relativepoint>
1561 </dc:group> 1567 </dc:group>
1564 </dc:filter> 1570 </dc:filter>
1565 </dc:macro> 1571 </dc:macro>
1566 1572
1567 <dc:macro name="basedata_7_waterlevels"> 1573 <dc:macro name="basedata_7_waterlevels">
1568 <dc:call-macro name="basedata_7_macro"> 1574 <dc:call-macro name="basedata_7_macro">
1569 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" /> 1575 <dc:variable name="start_year" expr="dc:date-format('yyyy', $start_time)" />
1576 <column name="{$wst_column_name}" ids="additionals-wstv-{$wst_column_position}-{$wst_id}" factory="staticwqkms" target_out="{$out}" info="{$info} [km {$deffrom} - {$defto}]" year="{dc:date-format('yyyy', $start_time)}" />
1570 </dc:call-macro> 1577 </dc:call-macro>
1571 </dc:macro> 1578 </dc:macro>
1572 1579
1573 <dc:macro name="basedata_7_waterlevels_wq"> 1580 <dc:macro name="basedata_7_waterlevels_wq">
1574 <dc:call-macro name="basedata_7_macro"> 1581 <dc:call-macro name="basedata_7_macro">
2052 2059
2053 <!-- Show only MW bed height and name it in a neutral way --> 2060 <!-- Show only MW bed height and name it in a neutral way -->
2054 <dc:macro name="bed-heights-factory_MW"> 2061 <dc:macro name="bed-heights-factory_MW">
2055 <dc:for-each> 2062 <dc:for-each>
2056 <dc:if test="$bedh_height_count > 0"> 2063 <dc:if test="$bedh_height_count > 0">
2057 <height factory="bedheight" target_out="{$out}" ids="bedheight-single-{$bedh_id}-{$bedh_year}-{$bedh_descr}" info="{$info}" description="{$bedh_descr}" /> 2064 <!-- REMARK: addition 'yaer' attribute is used by intelligent datacage filter of SINFO -->
2065 <height factory="bedheight" target_out="{$out}" ids="bedheight-single-{$bedh_id}-{$bedh_year}-{$bedh_descr}" info="{$info}" description="{$bedh_descr}" year="{$bedh_year}" />
2058 </dc:if> 2066 </dc:if>
2059 </dc:for-each> 2067 </dc:for-each>
2060 </dc:macro> 2068 </dc:macro>
2061 2069
2062 <dc:macro name="bed-heights-single"> 2070 <dc:macro name="bed-heights-single">
2063 <single> 2071 <single>
2064 <dc:context> 2072 <dc:context>
2065 <dc:call-macro name="bed-heights-statement" /> 2073 <dc:call-macro name="bed-heights-statement" />
2066 <dc:if test="dc:has-result()"> 2074 <dc:if test="dc:has-result()">
2067 <dc:group expr="dc:coalesce($bedh_year, 'sonstige')"> 2075 <dc:group expr="dc:coalesce($bedh_year, 'sonstige')">
2068 <heights name="{dc:group-key()}"> 2076 <heights name="{dc:group-key()}" description="{dc:group-key()}">
2069 <dc:call-macro name="bed-heights-factory_MW_TW_KL" /> 2077 <dc:call-macro name="bed-heights-factory_MW_TW_KL" />
2070 </heights> 2078 </heights>
2071 </dc:group> 2079 </dc:group>
2072 </dc:if> 2080 </dc:if>
2073 </dc:context> 2081 </dc:context>
2080 <dc:context> 2088 <dc:context>
2081 <dc:call-macro name="bed-heights-statement" /> 2089 <dc:call-macro name="bed-heights-statement" />
2082 <dc:filter expr="$bedh_height_count"> 2090 <dc:filter expr="$bedh_height_count">
2083 <dc:if test="dc:has-result()"> 2091 <dc:if test="dc:has-result()">
2084 <dc:group expr="dc:coalesce($bedh_year, 'sonstige')"> 2092 <dc:group expr="dc:coalesce($bedh_year, 'sonstige')">
2085 <heights name="{dc:group-key()}"> 2093 <heights name="{dc:group-key()}" description="{dc:group-key()}">
2086 <dc:call-macro name="bed-heights-factory_MW" /> 2094 <dc:call-macro name="bed-heights-factory_MW" />
2087 </heights> 2095 </heights>
2088 </dc:group> 2096 </dc:group>
2089 </dc:if> 2097 </dc:if>
2090 </dc:filter> 2098 </dc:filter>
2098 <dc:context> 2106 <dc:context>
2099 <dc:call-macro name="bed-heights-statement" /> 2107 <dc:call-macro name="bed-heights-statement" />
2100 <dc:filter expr="$bedh_max_count > 0 and $bedh_min_count > 0"> 2108 <dc:filter expr="$bedh_max_count > 0 and $bedh_min_count > 0">
2101 <dc:if test="dc:has-result()"> 2109 <dc:if test="dc:has-result()">
2102 <dc:group expr="dc:coalesce($bedh_year, 'sonstige')"> 2110 <dc:group expr="dc:coalesce($bedh_year, 'sonstige')">
2103 <heights name="{dc:group-key()}"> 2111 <heights name="{dc:group-key()}" description="{dc:group-key()}">
2104 <dc:call-macro name="bed-heights-factory_MW" /> 2112 <dc:call-macro name="bed-heights-factory_MW" />
2105 </heights> 2113 </heights>
2106 </dc:group> 2114 </dc:group>
2107 </dc:if> 2115 </dc:if>
2108 </dc:filter> 2116 </dc:filter>
3192 </dc:context> 3200 </dc:context>
3193 </dc:macro> 3201 </dc:macro>
3194 3202
3195 3203
3196 <!-- Common stuff --> 3204 <!-- Common stuff -->
3197
3198 <dc:macro name="km-filtered-wsts"> 3205 <dc:macro name="km-filtered-wsts">
3199 <dc:context connection="system"> 3206 <dc:context connection="system">
3200 <dc:statement> 3207 <dc:statement>
3201 SELECT w.kind AS kind, 3208 SELECT w.kind AS kind,
3202 w.id AS wst_id, 3209 w.id AS wst_id,
3203 wc.id AS wst_column_id, 3210 wc.id AS wst_column_id,
3204 wc.position AS wst_column_position, 3211 wc.position AS wst_column_position,
3205 wc.description AS info, 3212 wc.description AS info,
3206 w.description AS wst_description, 3213 w.description AS wst_description,
3214 ti.start_time AS start_time,
3215 ti.stop_time AS stop_time,
3207 COALESCE(wc.name, '') AS wst_column_name, 3216 COALESCE(wc.name, '') AS wst_column_name,
3208 wr.a AS deffrom, 3217 wr.a AS deffrom,
3209 wr.b AS defto, 3218 wr.b AS defto,
3210 w.sinfo_selection 3219 w.sinfo_selection
3211 FROM wst_columns wc 3220 FROM wst_columns wc
3212 JOIN wsts w ON wc.wst_id = w.id 3221 JOIN wsts w ON wc.wst_id = w.id
3213 JOIN wst_ranges wr ON wc.id = wr.wst_column_id 3222 JOIN wst_ranges wr ON wc.id = wr.wst_column_id
3223 LEFT JOIN time_intervals ti ON wc.time_interval_id = ti.id
3214 WHERE w.river_id = ${river_id} AND 3224 WHERE w.river_id = ${river_id} AND
3215 NOT((${tokm} &lt; wr.a) or (${fromkm} &gt; wr.b)) 3225 NOT((${tokm} &lt; wr.a) or (${fromkm} &gt; wr.b))
3216 ORDER BY wst_column_position 3226 ORDER BY wst_column_position
3217 </dc:statement> 3227 </dc:statement>
3218 <dc:macro-body /> 3228 <dc:macro-body />

http://dive4elements.wald.intevation.org