comparison flys-client/src/main/webapp/WEB-INF/stylesheets/fixoverview2html.xsl @ 5777:e95427ed80e5

Merged
author Sascha L. Teichmann <teichmann@intevation.de>
date Sun, 21 Apr 2013 10:46:59 +0200
parents a3b170869c77
children
comparison
equal deleted inserted replaced
5776:1126b9e00378 5777:e95427ed80e5
19 19
20 <xsl:variable name="km-pattern"> 20 <xsl:variable name="km-pattern">
21 <xsl:choose> 21 <xsl:choose>
22 <xsl:when test="$locale = 'de'">0,##</xsl:when> 22 <xsl:when test="$locale = 'de'">0,##</xsl:when>
23 <xsl:otherwise>0.##</xsl:otherwise> 23 <xsl:otherwise>0.##</xsl:otherwise>
24 </xsl:choose>
25 </xsl:variable>
26
27 <xsl:variable name="i18n-gauge">
28 <xsl:choose>
29 <xsl:when test="$locale = 'de'">Pegel</xsl:when>
30 <xsl:otherwise>Gauge</xsl:otherwise>
24 </xsl:choose> 31 </xsl:choose>
25 </xsl:variable> 32 </xsl:variable>
26 33
27 <xsl:variable name="i18n-event"> 34 <xsl:variable name="i18n-event">
28 <xsl:choose> 35 <xsl:choose>
253 <xsl:when test="@class = '0'"> / Q <xsl:value-of select="$i18n-around-mnq"/></xsl:when> 260 <xsl:when test="@class = '0'"> / Q <xsl:value-of select="$i18n-around-mnq"/></xsl:when>
254 <xsl:when test="@class = '1'"> / Q <xsl:value-of select="$i18n-around-mq"/></xsl:when> 261 <xsl:when test="@class = '1'"> / Q <xsl:value-of select="$i18n-around-mq"/></xsl:when>
255 <xsl:when test="@class = '2'"> / Q <xsl:value-of select="$i18n-around-mhq"/></xsl:when> 262 <xsl:when test="@class = '2'"> / Q <xsl:value-of select="$i18n-around-mhq"/></xsl:when>
256 <xsl:when test="@class = '3'"> / Q <xsl:value-of select="$i18n-above-hq5"/></xsl:when> 263 <xsl:when test="@class = '3'"> / Q <xsl:value-of select="$i18n-above-hq5"/></xsl:when>
257 </xsl:choose> 264 </xsl:choose>
265 <xsl:text>&#10;</xsl:text>
266 <xsl:value-of select="$i18n-gauge"/>
267 <xsl:text>:</xsl:text>
268 <xsl:call-template name="find-gauges">
269 <xsl:with-param name="start" select="@from"/>
270 <xsl:with-param name="stop" select="@to"/>
271 </xsl:call-template>
258 </xsl:attribute> 272 </xsl:attribute>
259 <xsl:text disable-output-escaping="yes"><![CDATA[&nbsp;]]></xsl:text> 273 <xsl:text disable-output-escaping="yes"><![CDATA[&nbsp;]]></xsl:text>
260 </div> 274 </div>
261 </xsl:template> 275 </xsl:template>
262 276
273 <td align="center"> 287 <td align="center">
274 <xsl:attribute name="title"><xsl:value-of select="@description"/></xsl:attribute> 288 <xsl:attribute name="title"><xsl:value-of select="@description"/></xsl:attribute>
275 <xsl:value-of select="@date"/> 289 <xsl:value-of select="@date"/>
276 </td> 290 </td>
277 </tr> 291 </tr>
292 </xsl:template>
293
294 <xsl:template match="text()" mode="gauge-list"/>
295 <xsl:template match="gauge" mode="gauge-list">
296 <xsl:text> </xsl:text><xsl:value-of select="@name"/>
297 </xsl:template>
298
299 <xsl:template name="find-gauges">
300 <xsl:param name="start"/>
301 <xsl:param name="stop"/>
302 <xsl:apply-templates mode="gauge-list"
303 select="/fixings/gauges/gauge[not((number(@to) &lt; number($start)) or (number(@from) &gt; number($stop)))]"/>
278 </xsl:template> 304 </xsl:template>
279 305
280 <xsl:template match="gauge" mode="gauges"> 306 <xsl:template match="gauge" mode="gauges">
281 <xsl:call-template name="emit-gap-gauge"> 307 <xsl:call-template name="emit-gap-gauge">
282 <xsl:with-param name="gauge" select="."/> 308 <xsl:with-param name="gauge" select="."/>

http://dive4elements.wald.intevation.org