Changeset 1077
- Timestamp:
- 11/28/07 09:55:15 (7 months ago)
- Files:
-
- trunk/examples/pages/txt/main_shop.xml (modified) (1 diff)
- trunk/src/main/resources/xsl/stub.xsl (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/examples/pages/txt/main_shop.xml
r1076 r1077 9 9 </div> 10 10 <div class="footer"> 11 <stub:form send-to-page="shop"> 11 <stub:form send-to-page="shop"> 12 12 <stub:itemframe id="shopData"> 13 <stub:item name="id" type="text"/> 14 <!--ixsl:attribute name="value"> 15 <ixsl:value-of select="/document/shopData/analyzable/@id"/> 16 </ixsl:attribute> 17 </stub:item--> 13 <stub:item name="id" type="dynamic" path="/document/shopData/analyzable/@id"/> 18 14 <stub:item name="title" type="text"/> 19 15 <stub:item name="url" type="text"/> 20 < !--ixsl:if test="/document/shopData/analyzable/@id"-->16 <ixsl:if test="/document/shopData/analyzable/@id"> 21 17 <stub:item name="status" type="select"> 22 18 <stub:option value="enabled">Aktiviert</stub:option> 23 19 <stub:option value="disabled">Deaktiviert</stub:option> 24 20 </stub:item> 25 < !--/ixsl:if-->21 </ixsl:if> 26 22 <stub:item name="action" type="submit" value="Speichern"/> 27 23 </stub:itemframe> trunk/src/main/resources/xsl/stub.xsl
r1073 r1077 231 231 <xsl:template match="stub:itemframe" name="stub:itemframe"> 232 232 <div> 233 <xsl:attribute name="class"> 233 <xsl:attribute name="class"> 234 234 <xsl:choose> 235 235 <xsl:when test="@class and not(@class = '')"> … … 244 244 <xsl:copy-of select="@*[local-name() != 'class']"/> 245 245 <ul> 246 <xsl:apply-templates select="node()"> 247 <xsl:with-param name="id" select="@id"/> 248 </xsl:apply-templates> 246 <xsl:apply-templates/> 249 247 </ul> 250 248 </div> … … 252 250 253 251 <xsl:template match="stub:item" name="stub:item"> 254 <xsl:param name="id" select=" @id"/>252 <xsl:param name="id" select="ancestor::stub:itemframe/@id"/> 255 253 <li> 256 254 <xsl:if test="not(@type = 'submit')"> … … 285 283 </xsl:attribute> 286 284 <xsl:copy-of select="@*[local-name() != 'id' and local-name() != 'name' and local-name() != 'mandatory']"/> 287 <ixsl: attribute name="value">288 < ixsl:if>289 <xsl: attribute name="test">290 <xsl:text>/document/forms/</xsl:text>291 <xsl:value-of select="$id"/>292 <xsl:text>/</xsl:text>293 <xsl:value-of select="@name"/>294 </xsl:attribute>285 <ixsl:if> 286 <xsl:attribute name="test"> 287 <xsl:text>/document/forms/</xsl:text> 288 <xsl:value-of select="$id"/> 289 <xsl:text>/</xsl:text> 290 <xsl:value-of select="@name"/> 291 </xsl:attribute> 292 <ixsl:attribute name="value"> 295 293 <ixsl:value-of> 296 294 <xsl:attribute name="select"> … … 301 299 </xsl:attribute> 302 300 </ixsl:value-of> 303 </ixsl: if>304 </ixsl: attribute>301 </ixsl:attribute> 302 </ixsl:if> 305 303 </input> 304 </xsl:when> 305 <xsl:when test="@type = 'dynamic'"> 306 <ixsl:if> 307 <xsl:attribute name="test"> 308 <xsl:value-of select="@path"/> 309 </xsl:attribute> 310 <input type="text"> 311 <xsl:attribute name="id"> 312 <xsl:value-of select="$id"/> 313 <xsl:text>_</xsl:text> 314 <xsl:value-of select="@name"/> 315 </xsl:attribute> 316 <xsl:attribute name="name"> 317 <xsl:value-of select="$id"/> 318 <xsl:text>_</xsl:text> 319 <xsl:value-of select="@name"/> 320 </xsl:attribute> 321 <xsl:copy-of select="@*[local-name() != 'id' and local-name() != 'name' and local-name() != 'type' and local-name() != 'path' and local-name() != 'mandatory']"/> 322 <ixsl:attribute name="value"> 323 <ixsl:value-of> 324 <xsl:attribute name="select"> 325 <xsl:value-of select="@path"/> 326 </xsl:attribute> 327 </ixsl:value-of> 328 </ixsl:attribute> 329 </input> 330 </ixsl:if> 306 331 </xsl:when> 307 332 <xsl:when test="@type = 'select'">
