Ignore:
Timestamp:
2003-01-17T11:04:39+13:00 (21 years ago)
Author:
kjdon
Message:

tidy up, cgi args changes, other stuff

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl3/interfaces/default/transform/about.xsl

    r3655 r3686  
    1515<body xsl:use-attribute-sets="body-style">
    1616<center>
     17<table width='537'>
     18<tr><td>
    1719<xsl:apply-templates select="response/collection|response/serviceCluster"><xsl:with-param name="collName" select="$collName"/></xsl:apply-templates>
     20</td></tr></table>
    1821</center>
    1922<xsl:call-template name="greenstoneFooter"/>
     
    2225</xsl:template>
    2326
    24 <xsl:template match="collection">
    25 <xsl:param name="collName">x</xsl:param>
     27<xsl:template match="collection|serviceCluster">
     28<xsl:param name="collName">coll-name</xsl:param>
     29<xsl:if test='name()="collection"'>
    2630<xsl:call-template name="collectionPageBanner">
    2731<xsl:with-param name="collName"><xsl:value-of select="$collName"/></xsl:with-param>
    28 <xsl:with-param name="collIcon"><xsl:value-of select="metadataList/metadata[@name='iconCollection']"/></xsl:with-param>
     32<xsl:with-param name="collIcon"><xsl:value-of select="metadataList/metadata[@name='colIcon']"/></xsl:with-param>
    2933</xsl:call-template>
     34</xsl:if>
     35<xsl:if test='name()="serviceCluster"'>
     36<xsl:call-template name="clusterPageBanner">
     37<xsl:with-param name="clusterName"><xsl:value-of select="$collName"/></xsl:with-param></xsl:call-template>
     38</xsl:if>
    3039<p/><xsl:apply-templates select="metadataList">
    3140<xsl:with-param name="collName"><xsl:value-of select="$collName"/></xsl:with-param>
    3241</xsl:apply-templates>
    33 <p/><xsl:apply-templates select="serviceList" mode="collection">
     42<p/><xsl:apply-templates select="serviceList">
    3443<xsl:with-param name="collName"><xsl:value-of select="$collName"/></xsl:with-param>
    3544</xsl:apply-templates>
    3645</xsl:template>
    37 
    38 <xsl:template match="serviceCluster">
    39 <xsl:param name="collName">x</xsl:param>
    40 <xsl:call-template name="clusterPageBanner">
    41 <xsl:with-param name="clusterName"><xsl:value-of select="$collName"/></xsl:with-param></xsl:call-template>
    42 <p/><xsl:apply-templates select="metadataList">
    43 <xsl:with-param name="collName"><xsl:value-of select="$collName"/></xsl:with-param>
    44 </xsl:apply-templates>
    45 <p/><xsl:apply-templates select="serviceList" mode="cluster">
    46 <xsl:with-param name="collName"><xsl:value-of select="$collName"/></xsl:with-param>
    47 </xsl:apply-templates>
    48 </xsl:template>
    49 
    5046
    5147
     
    5450<h2><xsl:call-template name="text"><xsl:with-param name="key">about.description</xsl:with-param></xsl:call-template></h2>
    5551<p/>
    56 <table>
     52<table width='537'>
    5753<xsl:for-each select="metadata">
    58 <tr><td><b><xsl:value-of select="@name"/></b></td><td><xsl:value-of select="."/></td></tr>
     54<tr valign='top'><td><b><xsl:value-of select="@name"/></b></td><td><xsl:value-of select="."/></td></tr>
    5955</xsl:for-each>
    6056</table>
    6157</xsl:template>
    6258
    63 <xsl:template match="serviceList" mode="collection">
     59<xsl:template match="serviceList">
    6460<xsl:param name="collName">coll-name</xsl:param>
    6561<xsl:variable name="library" select="ancestor::page/config/library_name"/>
    6662<h2><xsl:call-template name="text"><xsl:with-param name="key">about.services</xsl:with-param></xsl:call-template></h2>
    6763<table>
    68 <xsl:for-each select="service[@type='query']">
    69 <xsl:variable name="serviceName"><xsl:value-of select="@name"/></xsl:variable>
    70 <tr>
    71 <xsl:if test="contains($serviceName, 'Query')">
    72 <xsl:variable name="s-type"><xsl:value-of select="substring-before($serviceName, 'Query')"/></xsl:variable>
    73 <td><a href="{$library}?a=q&amp;sa={$s-type}&amp;c={$collName}"><xsl:value-of select="$serviceName"/></a></td>
     64<xsl:for-each select="service">
     65<xsl:variable name="action"><xsl:choose>
     66        <xsl:when test="@type='query'">q</xsl:when>
     67        <xsl:when test="@type='browse'">b</xsl:when>
     68        <xsl:when test="@type='process'">pr</xsl:when>
     69        <xsl:when test="@type='applet'">a</xsl:when>
     70        <xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
     71</xsl:choose></xsl:variable>
     72<xsl:if test="$action !='DO_NOT_DISPLAY'">
     73<tr><td><a href="{$library}?a={$action}&amp;rt=d&amp;s={@name}&amp;c={$collName}"><xsl:value-of select="@name"/></a></td></tr>
    7474</xsl:if>
    75 <xsl:if test="contains($serviceName, 'Browse')">
    76 <xsl:variable name="s-type"><xsl:value-of select="substring-before($serviceName, 'Browse')"/></xsl:variable>
    77 <td><a href="{$library}?a=b&amp;sa={$s-type}&amp;c={$collName}"><xsl:value-of select="$serviceName"/></a></td>
    78 </xsl:if>
    79 <xsl:if test="contains($serviceName, 'Applet')">
    80 <xsl:variable name="s-type"><xsl:value-of select="substring-before($serviceName, 'Applet')"/></xsl:variable>
    81 <td><a href="{$library}?a=a&amp;sa=d&amp;s={$s-type}&amp;c={$collName}"><xsl:value-of select="$serviceName"/></a></td>
    82 </xsl:if>
    83 </tr>
    8475</xsl:for-each>
    8576</table>
     
    8879
    8980
    90 <xsl:template match="serviceList" mode="cluster">
    91 <xsl:param name="collName">coll-name</xsl:param>
    92 <xsl:variable name="library" select="ancestor::page/config/library_name"/>
    93 <h2><xsl:call-template name="text"><xsl:with-param name="key">about.services</xsl:with-param></xsl:call-template></h2>
    94 <table>
    95 <xsl:for-each select="service">
    96 <tr><td><a href="{$library}?a=pr&amp;sa=d&amp;c={$collName}&amp;s={@name}"><xsl:value-of select="@name"/></a></td></tr>
    97 </xsl:for-each>
    98 </table>
    99 <xsl:call-template name="greenBar"/>
    100 </xsl:template>
    10181
    10282</xsl:stylesheet> 
Note: See TracChangeset for help on using the changeset viewer.