comparison flys-artifacts/doc/conf/meta-data.xml @ 5404:08262e0ce57a

Add buildings with kinds to datacage
author Andre Heinecke <aheinecke@intevation.de>
date Mon, 25 Mar 2013 15:02:04 +0100
parents f099ca10684e
children 5ca06120b918
comparison
equal deleted inserted replaced
5403:e1cd77ddcbc4 5404:08262e0ce57a
1519 </inofficial> 1519 </inofficial>
1520 </hws_points> 1520 </hws_points>
1521 </dc:macro> 1521 </dc:macro>
1522 1522
1523 1523
1524 <dc:macro name="flood-map-buildings"> 1524 <dc:macro name="flood-map-buildings">
1525 <dc:context> 1525 <dc:context>
1526 <dc:statement> 1526 <dc:statement>
1527 SELECT count(*) as km_exists, name as name 1527 SELECT DISTINCT
1528 FROM buildings WHERE river_id = ${river_id} GROUP BY name 1528 b.kind_id AS building_kind_id,
1529 </dc:statement> 1529 bk.name AS building_kind
1530 <dc:elements> 1530 FROM buildings b
1531 <dc:if test="$km_exists>0"> 1531 JOIN building_kinds bk ON b.kind_id = bk.id
1532 <building> 1532 WHERE river_id = ${river_id}
1533 <dc:attribute name="factory" value="wmsbuildingsfactory"/> 1533 </dc:statement>
1534 <dc:attribute name="ids" value="${river_id};${name}"/> 1534 <dc:elements>
1535 <dc:attribute name="name" value="${name}"/> 1535 <buildings>
1536 </building> 1536 <dc:attribute name="description" value="${building_kind}"/>
1537 </dc:if> 1537 <dc:attribute name="factory" value="wmsbuildingsfactory"/>
1538 </dc:elements> 1538 <dc:attribute name="ids" value="${river_id};${building_kind};${building_kind_id}"/>
1539 </dc:context> 1539 </buildings>
1540 </dc:macro> 1540 </dc:elements>
1541 </dc:context>
1542 </dc:macro>
1541 <dc:macro name="flood-map-fixpoints"> 1543 <dc:macro name="flood-map-fixpoints">
1542 <dc:context> 1544 <dc:context>
1543 <dc:statement> 1545 <dc:statement>
1544 SELECT count(*) as km_exists, name as name 1546 SELECT count(*) as km_exists, name as name
1545 FROM fixpoints WHERE river_id = ${river_id} GROUP BY name 1547 FROM fixpoints WHERE river_id = ${river_id} GROUP BY name

http://dive4elements.wald.intevation.org