Mercurial > dive4elements > gnv-client
comparison gnv/src/main/webapp/WEB-INF/config/templates/describe-ui-static.xsl @ 394:14eecfde4607
Render links to step back to previous states into gui. Added controller to advance back to these states.
gnv/trunk@538 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Wed, 13 Jan 2010 22:17:02 +0000 |
parents | 416ff31f6273 |
children | 002a4d38c16d |
comparison
equal
deleted
inserted
replaced
393:d812c5b62eb4 | 394:14eecfde4607 |
---|---|
2 <xsl:stylesheet version="1.0" | 2 <xsl:stylesheet version="1.0" |
3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | 3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform" |
4 xmlns="http://www.w3.org/2002/xforms" | 4 xmlns="http://www.w3.org/2002/xforms" |
5 xmlns:xform="http://www.w3.org/2002/xforms" | 5 xmlns:xform="http://www.w3.org/2002/xforms" |
6 xmlns:art="http://www.intevation.de/2009/artifacts"> | 6 xmlns:art="http://www.intevation.de/2009/artifacts"> |
7 <xsl:output method="html" version="1.0" encoding="UTF-8" omit-xml-declaration="no"/> | 7 |
8 <xsl:output method="html" version="1.0" encoding="UTF-8" omit-xml-declaration="no" /> | |
9 | |
10 <xsl:param name="back-url"/> | |
11 | |
12 <!-- start parsing document --> | |
13 <xsl:template match="*"> | |
14 <table class="static"> | |
15 <xsl:apply-templates /> | |
16 </table> | |
17 </xsl:template> | |
18 | |
8 | 19 |
20 <!-- match multi select boxes --> | |
9 <xsl:template match="xform:select"> | 21 <xsl:template match="xform:select"> |
10 <xsl:variable name="selectName" select="@ref"/> | 22 <xsl:variable name="state" select="@art:state" /> |
11 <div id="timeseriesfilter"> | 23 <tr> |
12 <table> | 24 <td class="historyback"> |
13 <tr> | 25 <xsl:if test="$state != ''"> |
14 <th class="parameter"><xsl:value-of select="xform:label"/>:</th> | 26 <a href="{$back-url}?target={$state}">[X]</a> |
15 <td> | 27 </xsl:if> |
16 <table> | 28 </td> |
17 <xsl:apply-templates select="xform:choices/xform:item" mode="table"/> | 29 <th class="parameter"><xsl:value-of select="xform:label" /></th> |
18 </table> | 30 <td><xsl:apply-templates select="xform:choices" /></td> |
19 </td> | 31 </tr> |
20 </tr> | |
21 </table> | |
22 </div> | |
23 </xsl:template> | 32 </xsl:template> |
24 | 33 |
25 | 34 |
26 <xsl:template match="xform:item" mode="table"> | 35 <!-- match select boxes --> |
27 <xsl:if test="@selected = 'true'"> | 36 <xsl:template match="xform:select1"> |
28 <tr> | 37 <xsl:variable name="state" select="@art:state" /> |
29 <td class="value"><xsl:value-of select="./xform:label"/></td> | 38 <tr> |
30 </tr> | 39 <td class="historyback"> |
31 </xsl:if> | 40 <xsl:if test="$state != ''"> |
41 <a href="{$back-url}?target={$state}">[X]</a> | |
42 </xsl:if> | |
43 </td> | |
44 <th class="parameter"><xsl:value-of select="xform:label" /></th> | |
45 <td><xsl:apply-templates select="xform:choices" /></td> | |
46 </tr> | |
32 </xsl:template> | 47 </xsl:template> |
48 | |
33 | 49 |
34 | 50 <!-- match item list of select boxes or multi select boxes --> |
35 <xsl:template match="xform:select1"> | 51 <xsl:template match="xform:choices"> |
36 <xsl:variable name="selectName" select="@ref"/> | 52 <table class="choices"><xsl:apply-templates select="xform:item" /></table> |
37 <div id="timeseriesfilter"> | |
38 <table> | |
39 <tr> | |
40 <th class="parameter"><xsl:value-of select="xform:label"/>:</th> | |
41 <td><xsl:value-of select="./xform:choices/xform:item/xform:label" /></td> | |
42 </tr> | |
43 </table> | |
44 </div> | |
45 </xsl:template> | |
46 | |
47 | |
48 <xsl:template match="xform:group"> | |
49 <xsl:variable name="inputName" select="xform:label"/> | |
50 <div id="timeseriesfilter"> | |
51 <table> | |
52 <tr> | |
53 <th class="parameter"><xsl:value-of select="xform:label"/>:</th> | |
54 <td> | |
55 <table> | |
56 <xsl:apply-templates select="xform:input" mode="table"/> | |
57 </table> | |
58 </td> | |
59 </tr> | |
60 </table> | |
61 </div> | |
62 </xsl:template> | 53 </xsl:template> |
63 | 54 |
64 | 55 |
65 <xsl:template match="xform:input" mode="table"> | 56 <!-- match item of select boxes or multi select boxes --> |
57 <xsl:template match="xform:item"> | |
66 <tr> | 58 <tr> |
67 <td class="value"> | 59 <td class="value"><xsl:value-of select="xform:label" /></td> |
68 <xsl:value-of select="./xform:label"/> <xsl:value-of select="./xform:value"/> | 60 </tr> |
61 </xsl:template> | |
62 | |
63 | |
64 <!-- match group items --> | |
65 <xsl:template match="xform:group"> | |
66 <xsl:variable name="state" select="@art:state" /> | |
67 <tr> | |
68 <td class="historyback"> | |
69 <xsl:if test="$state != ''"> | |
70 <a href="{$back-url}?target={$state}">[X]</a> | |
71 </xsl:if> | |
72 </td> | |
73 <th class="parameter"><xsl:value-of select="xform:label" /></th> | |
74 <td> | |
75 <table><xsl:apply-templates select="xform:input" /></table> | |
69 </td> | 76 </td> |
70 </tr> | 77 </tr> |
71 </xsl:template> | 78 </xsl:template> |
72 | 79 |
73 | 80 |
81 <!-- match single group item --> | |
82 <xsl:template match="xform:input"> | |
83 <tr> | |
84 <td class="value"><xsl:value-of select="xform:label" /> <xsl:value-of select="xform:value" /></td> | |
85 </tr> | |
86 </xsl:template> | |
87 | |
74 </xsl:stylesheet> | 88 </xsl:stylesheet> |