[2] | 1 | <?xml version="1.0" encoding="iso-8859-1"?> |
---|
| 2 | |
---|
| 3 | <!-- |
---|
| 4 | module : |
---|
| 5 | creation des élements platforms de formulaire |
---|
| 6 | |
---|
| 7 | source : |
---|
| 8 | /usr/home/fplod/incas/bibnemo/src/bibnemomaf/platform_db.xsl sur aedon.locean-ipsl.upmc.fr |
---|
| 9 | |
---|
| 10 | |
---|
| 11 | update : |
---|
| 12 | fplod 2007-05-18T10:25:06Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
| 13 | correction pour cause de dysfonctionnement sous firefox (mais ok sous safari) : |
---|
| 14 | Le 1er choix est modifié si on clique sur un des choix suivant |
---|
| 15 | fplod 2007-04-26T10:14:40Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
| 16 | creation |
---|
| 17 | --> |
---|
| 18 | |
---|
| 19 | <xsl:stylesheet |
---|
| 20 | id="id" version="1.0" |
---|
| 21 | xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> |
---|
| 22 | |
---|
| 23 | <xsl:template name="platforms"> |
---|
| 24 | <xsl:param name="usernemo"/> |
---|
| 25 | <xsl:param name="visu_modif"/> |
---|
| 26 | |
---|
| 27 | <xsl:text>
</xsl:text> |
---|
| 28 | <xsl:element name="fieldset"> |
---|
| 29 | <xsl:attribute name="id">platforms</xsl:attribute> |
---|
| 30 | <xsl:text>
</xsl:text> |
---|
| 31 | <xsl:element name="legend"> |
---|
| 32 | Used platforms |
---|
| 33 | </xsl:element> |
---|
| 34 | <xsl:text>
</xsl:text> |
---|
| 35 | <!-- ne plait pas à firefox ++ |
---|
| 36 | <xsl:element name="label"> |
---|
| 37 | --> |
---|
| 38 | <xsl:for-each select="$usernemo/platforms/platform"> |
---|
| 39 | <xsl:sort order="ascending" data-type="text" select="@code"/> |
---|
| 40 | <xsl:text>
</xsl:text> |
---|
| 41 | <xsl:comment><xsl:value-of select="./value"/></xsl:comment> |
---|
| 42 | <xsl:choose> |
---|
| 43 | <xsl:when test="@code != 'zzz_other'"> |
---|
| 44 | <xsl:element name="input"> |
---|
| 45 | <xsl:attribute name="name"> |
---|
| 46 | <xsl:value-of select="name()"/><xsl:text>_</xsl:text><xsl:value-of select="@code"/> |
---|
| 47 | </xsl:attribute> |
---|
| 48 | <xsl:attribute name="type">checkbox</xsl:attribute> |
---|
| 49 | <xsl:attribute name="value"><xsl:value-of select="./name"/></xsl:attribute> |
---|
| 50 | <xsl:if test="$visu_modif= 'visu'"> |
---|
| 51 | <xsl:attribute name="readonly">1</xsl:attribute> |
---|
| 52 | </xsl:if> |
---|
| 53 | <xsl:if test="./value = 'yes'"> |
---|
| 54 | <xsl:attribute name="checked">1</xsl:attribute> |
---|
| 55 | </xsl:if> |
---|
| 56 | <xsl:value-of select="./name"/> |
---|
| 57 | </xsl:element> |
---|
| 58 | </xsl:when> |
---|
| 59 | <xsl:when test="@code = 'zzz_other'"> |
---|
| 60 | <xsl:element name="label"> |
---|
| 61 | Other : |
---|
| 62 | <xsl:element name="input"> |
---|
| 63 | <xsl:attribute name="name"> |
---|
| 64 | <xsl:value-of select="name()"/><xsl:text>_</xsl:text><xsl:value-of select="@code"/> |
---|
| 65 | </xsl:attribute> |
---|
| 66 | <xsl:attribute name="type">text</xsl:attribute> |
---|
| 67 | <xsl:attribute name="value"><xsl:value-of select="./value"/></xsl:attribute> |
---|
| 68 | </xsl:element> |
---|
| 69 | </xsl:element> |
---|
| 70 | </xsl:when> |
---|
| 71 | </xsl:choose> |
---|
| 72 | </xsl:for-each> |
---|
| 73 | <!-- ne plait pas à firefox ++ |
---|
| 74 | </xsl:element> |
---|
| 75 | --> |
---|
| 76 | <xsl:text>
</xsl:text> |
---|
| 77 | </xsl:element> |
---|
| 78 | <xsl:text>
</xsl:text> |
---|
| 79 | </xsl:template> |
---|
| 80 | |
---|
| 81 | </xsl:stylesheet> |
---|