mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-07 01:54:22 +00:00
[DS-284] alternate odd and even styles correctly on table rows in Item Summary view
git-svn-id: http://scm.dspace.org/svn/repo/dspace/trunk@4645 9c30dcfa-912a-0410-8fc2-9e0234be79fd
This commit is contained in:
@@ -439,7 +439,30 @@
|
||||
<!-- Generate the info about the item from the metadata section -->
|
||||
<xsl:template match="dim:dim" mode="itemSummaryView-DIM">
|
||||
<table class="ds-includeSet-table">
|
||||
<!--
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
</xsl:call-template>
|
||||
</table>
|
||||
</xsl:template>
|
||||
|
||||
<!-- render each field on a row, alternating phase between odd and even -->
|
||||
<!-- recursion needed since not every row appears for each Item. -->
|
||||
<xsl:template name="itemSummaryView-DIM-fields">
|
||||
<xsl:param name="clause" select="'1'"/>
|
||||
<xsl:param name="phase" select="'even'"/>
|
||||
<xsl:variable name="otherPhase">
|
||||
<xsl:choose>
|
||||
<xsl:when test="$phase = 'even'">
|
||||
<xsl:text>odd</xsl:text>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:text>even</xsl:text>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
|
||||
<xsl:choose>
|
||||
|
||||
<!-- artifact?
|
||||
<tr class="ds-table-row odd">
|
||||
<td><span class="bold"><i18n:text>xmlui.dri2xhtml.METS-1.0.item-preview</i18n:text>:</span></td>
|
||||
<td>
|
||||
@@ -461,8 +484,10 @@
|
||||
</xsl:choose>
|
||||
</td>
|
||||
</tr>-->
|
||||
<tr class="ds-table-row even">
|
||||
|
||||
<!-- Title row -->
|
||||
<xsl:when test="$clause = 1">
|
||||
<tr class="ds-table-row {$phase}">
|
||||
<td><span class="bold"><i18n:text>xmlui.dri2xhtml.METS-1.0.item-title</i18n:text>: </span></td>
|
||||
<td>
|
||||
<span class="Z3988">
|
||||
@@ -488,8 +513,15 @@
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
<xsl:if test="dim:field[@element='contributor'][@qualifier='author'] or dim:field[@element='creator'] or dim:field[@element='contributor']">
|
||||
<tr class="ds-table-row odd">
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
<xsl:with-param name="clause" select="($clause + 1)"/>
|
||||
<xsl:with-param name="phase" select="$otherPhase"/>
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
|
||||
<!-- Author(s) row -->
|
||||
<xsl:when test="$clause = 2 and (dim:field[@element='contributor'][@qualifier='author'] or dim:field[@element='creator'] or dim:field[@element='contributor'])">
|
||||
<tr class="ds-table-row {$phase}">
|
||||
<td><span class="bold"><i18n:text>xmlui.dri2xhtml.METS-1.0.item-author</i18n:text>:</span></td>
|
||||
<td>
|
||||
<xsl:choose>
|
||||
@@ -528,9 +560,15 @@
|
||||
</xsl:choose>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:if>
|
||||
<xsl:if test="dim:field[@element='description' and @qualifier='abstract']">
|
||||
<tr class="ds-table-row even">
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
<xsl:with-param name="clause" select="($clause + 1)"/>
|
||||
<xsl:with-param name="phase" select="$otherPhase"/>
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
|
||||
<!-- Abstract row -->
|
||||
<xsl:when test="$clause = 3 and (dim:field[@element='description' and @qualifier='abstract'])">
|
||||
<tr class="ds-table-row {$phase}">
|
||||
<td><span class="bold"><i18n:text>xmlui.dri2xhtml.METS-1.0.item-abstract</i18n:text>:</span></td>
|
||||
<td>
|
||||
<xsl:if test="count(dim:field[@element='description' and @qualifier='abstract']) > 1">
|
||||
@@ -547,9 +585,15 @@
|
||||
</xsl:if>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:if>
|
||||
<xsl:if test="dim:field[@element='description' and not(@qualifier)]">
|
||||
<tr class="ds-table-row odd">
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
<xsl:with-param name="clause" select="($clause + 1)"/>
|
||||
<xsl:with-param name="phase" select="$otherPhase"/>
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
|
||||
<!-- Description row -->
|
||||
<xsl:when test="$clause = 4 and (dim:field[@element='description' and not(@qualifier)])">
|
||||
<tr class="ds-table-row {$phase}">
|
||||
<td><span class="bold"><i18n:text>xmlui.dri2xhtml.METS-1.0.item-description</i18n:text>:</span></td>
|
||||
<td>
|
||||
<xsl:if test="count(dim:field[@element='description' and not(@qualifier)]) > 1 and not(count(dim:field[@element='description' and @qualifier='abstract']) > 1)">
|
||||
@@ -566,9 +610,15 @@
|
||||
</xsl:if>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:if>
|
||||
<xsl:if test="dim:field[@element='identifier' and @qualifier='uri']">
|
||||
<tr class="ds-table-row even">
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
<xsl:with-param name="clause" select="($clause + 1)"/>
|
||||
<xsl:with-param name="phase" select="$otherPhase"/>
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
|
||||
<!-- identifier.uri row -->
|
||||
<xsl:when test="$clause = 5 and (dim:field[@element='identifier' and @qualifier='uri'])">
|
||||
<tr class="ds-table-row {$phase}">
|
||||
<td><span class="bold"><i18n:text>xmlui.dri2xhtml.METS-1.0.item-uri</i18n:text>:</span></td>
|
||||
<td>
|
||||
<xsl:for-each select="dim:field[@element='identifier' and @qualifier='uri']">
|
||||
@@ -584,9 +634,15 @@
|
||||
</xsl:for-each>
|
||||
</td>
|
||||
</tr>
|
||||
</xsl:if>
|
||||
<xsl:if test="dim:field[@element='date' and @qualifier='issued']">
|
||||
<tr class="ds-table-row odd">
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
<xsl:with-param name="clause" select="($clause + 1)"/>
|
||||
<xsl:with-param name="phase" select="$otherPhase"/>
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
|
||||
<!-- date.issued row -->
|
||||
<xsl:when test="$clause = 6 and (dim:field[@element='date' and @qualifier='issued'])">
|
||||
<tr class="ds-table-row {$phase}">
|
||||
<td><span class="bold"><i18n:text>xmlui.dri2xhtml.METS-1.0.item-date</i18n:text>:</span></td>
|
||||
<td>
|
||||
<xsl:for-each select="dim:field[@element='date' and @qualifier='issued']">
|
||||
@@ -597,8 +653,23 @@
|
||||
</xsl:for-each>
|
||||
</td>
|
||||
</tr>
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
<xsl:with-param name="clause" select="($clause + 1)"/>
|
||||
<xsl:with-param name="phase" select="$otherPhase"/>
|
||||
</xsl:call-template>
|
||||
</xsl:when>
|
||||
|
||||
<!-- recurse without changing phase if we didn't output anything -->
|
||||
<xsl:otherwise>
|
||||
<!-- IMPORTANT: This test should be updated if clauses are added! -->
|
||||
<xsl:if test="$clause < 7">
|
||||
<xsl:call-template name="itemSummaryView-DIM-fields">
|
||||
<xsl:with-param name="clause" select="($clause + 1)"/>
|
||||
<xsl:with-param name="phase" select="$phase"/>
|
||||
</xsl:call-template>
|
||||
</xsl:if>
|
||||
</table>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:template>
|
||||
|
||||
|
||||
|
@@ -68,6 +68,7 @@
|
||||
- [DS-424] Export metadata button displayed in JSPUI Administration List of withdrawn items
|
||||
|
||||
(Larry Stone)
|
||||
- [DS-284] alternate odd and even styles correctly on table rows in Item Summary view
|
||||
- [DS-393] Fix DCDate and submission timezone bugs that changed date on page reload
|
||||
- [DS-377] Add META tags identifying DSpace source version
|
||||
- [DS-373] Fix "Letter" link URLs in 2nd-stage Browse
|
||||
@@ -80,7 +81,6 @@
|
||||
- [DS-338] Disable cache advice (Expires header) on Bitstream download that requires authorization (XMLUI)
|
||||
- [DS-285] Respond to If-Modified-Since request header in XMLUI, also provide Last-Modified response header for Bitstreams
|
||||
- [DS-288] Configurable option to hide metadata fields in public UIs and OAI-PMH
|
||||
- [DS-236] Authority control for metadata fields and Choice Authority plugin framework
|
||||
- [DS-128] Fix repositioning on submission pages after add button is clicked (XMLUI)
|
||||
- [DS-255] Protect submission from being lost if exception occurs in CompleteStep
|
||||
- [DS-254] Fix response for authorization failure on Bitstream when user is logged-in
|
||||
@@ -95,6 +95,9 @@
|
||||
- [DS-276] Patch to fix spelling error in Exception page
|
||||
- [DS-280] build.xml fails for ant versions below 1.7
|
||||
|
||||
(Larry Stone / Andrea Bollini)
|
||||
- [DS-236] Authority control for metadata fields and Choice Authority plugin framework
|
||||
|
||||
(Mark Diggory / Stuart Lewis)
|
||||
- [DS-201] handle.jar upgraded to version 6.2
|
||||
|
||||
|
Reference in New Issue
Block a user