Bugzilla – Attachment 131385 Details for
Bug 15594
Sequence of MARC 260 subfields different on XSLT result list and detail page
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15594: (QA follow-up) Move span to publisher name, fix whitespace, only add spaces once per loop
Bug-15594-QA-follow-up-Move-span-to-publisher-name.patch (text/plain), 10.98 KB, created by
Nick Clemens
on 2022-03-04 16:50:18 UTC
(
hide
)
Description:
Bug 15594: (QA follow-up) Move span to publisher name, fix whitespace, only add spaces once per loop
Filename:
MIME Type:
Creator:
Nick Clemens
Created:
2022-03-04 16:50:18 UTC
Size:
10.98 KB
patch
obsolete
>From b9041a4fb63485ceba172ddf4a0d6181188987f7 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Fri, 4 Mar 2022 16:48:19 +0000 >Subject: [PATCH] Bug 15594: (QA follow-up) Move span to publisher name, fix > whitespace, only add spaces once per loop > >This patch updates the whitespace for readbility >Moves the Ogranization span to the subfield b, publisher name only >Moves check for last/whitespace to the loop > >Signed-off-by: Nick Clemens <nick@bywatersolutions.com> >--- > .../en/xslt/MARC21slim2intranetDetail.xsl | 56 ++++++------- > .../en/xslt/MARC21slim2OPACDetail.xsl | 78 +++++++++---------- > 2 files changed, 61 insertions(+), 73 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >index 976fbb018f..656cd450dd 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >@@ -284,42 +284,36 @@ > <span class="results_summary publisher"><span class="label">Publication details: </span> > <xsl:for-each select="marc:datafield[@tag=260]"> > <xsl:for-each select="marc:subfield"> >- <xsl:if test="@code='a'"> >- <a> >- <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=pl:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >- <xsl:value-of select="current()"/> >- </a> >- <xsl:if test="position() != last()"> >- <xsl:text> </xsl:text> >+ <xsl:if test="@code='a'"> >+ <a> >+ <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=pl:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >+ <xsl:value-of select="current()"/> >+ </a> >+ </xsl:if> >+ <xsl:if test="@code='b'"> >+ <a> >+ <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=Provider:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >+ <xsl:value-of select="current()"/> >+ </a> >+ </xsl:if> >+ <xsl:if test="@code='c'"> >+ <a> >+ <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=copydate:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >+ <xsl:value-of select="current()"/> >+ </a> >+ </xsl:if> >+ <xsl:if test="@code='g'"> >+ <xsl:call-template name="chopPunctuation"> >+ <xsl:with-param name="chopString"> >+ <xsl:value-of select="current()"/> >+ </xsl:with-param> >+ </xsl:call-template> > </xsl:if> >- <xsl:text> </xsl:text> >- </xsl:if> >- <xsl:if test="@code='b'"> >- <a> >- <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=Provider:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >- <xsl:value-of select="current()"/> >- </a> >- <xsl:text> </xsl:text> >- </xsl:if> >- <xsl:if test="@code='c'"> >- <a> >- <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=copydate:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >- <xsl:value-of select="current()"/> >- </a> > <xsl:if test="position() != last()"> > <xsl:text> </xsl:text> > </xsl:if> >- <xsl:text> </xsl:text> >- </xsl:if> >- <xsl:if test="@code='g'"> >- <xsl:call-template name="chopPunctuation"> >- <xsl:with-param name="chopString"> >- <xsl:value-of select="current()"/> >- </xsl:with-param> >- </xsl:call-template> >- </xsl:if> > </xsl:for-each> >- <xsl:choose><xsl:when test="position()=last()"><xsl:text></xsl:text></xsl:when><xsl:otherwise><xsl:text>; </xsl:text></xsl:otherwise></xsl:choose> >+ <xsl:choose><xsl:when test="position()=last()"><xsl:text></xsl:text></xsl:when><xsl:otherwise><xsl:text>; </xsl:text></xsl:otherwise></xsl:choose> > </xsl:for-each> > </span> > </xsl:when> >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >index 2c760d115d..8f02316945 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >@@ -326,49 +326,43 @@ > <span class="results_summary publisher"><span class="label">Publication details: </span> > <xsl:for-each select="marc:datafield[@tag=260]"> > <xsl:for-each select="marc:subfield"> >- <xsl:if test="@code='a'"> >- <span property="publisher" typeof="Organization"> >- <span class="publisher_place" property="location"> >- <a> >- <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=pl:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >- <xsl:value-of select="current()"/> >- </a> >+ <xsl:if test="@code='a'"> >+ <span class="publisher_place" property="location"> >+ <a> >+ <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=pl:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >+ <xsl:value-of select="current()"/> >+ </a> >+ </span> >+ </xsl:if> >+ <xsl:if test="@code='b'"> >+ <span property="publisher" typeof="Organization"> >+ <span property="name" class="publisher_name"> >+ <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Provider:<xsl:value-of select="str:encode-uri(current(), true())"/></xsl:attribute> >+ <xsl:value-of select="current()"/> >+ </a> >+ </span> >+ </span> >+ </xsl:if> >+ <xsl:if test="@code='c'"> >+ <span property="datePublished" class="publisher_date"> >+ <a> >+ <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=copydate:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >+ <xsl:value-of select="current()"/> >+ </a> >+ </span> >+ </xsl:if> >+ <xsl:if test="@code='g'"> >+ <span property="datePublished" class="publisher_date"> >+ <xsl:call-template name="chopPunctuation"> >+ <xsl:with-param name="chopString"> >+ <xsl:value-of select="current()"/> >+ </xsl:with-param> >+ </xsl:call-template> > </span> >- </span> >- <xsl:if test="position() != last()"> >- <xsl:text> </xsl:text> >- </xsl:if> >- <xsl:text> </xsl:text> >- </xsl:if> >- <xsl:if test="@code='b'"> >- <span property="name" class="publisher_name"> >- <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Provider:<xsl:value-of select="str:encode-uri(current(), true())"/></xsl:attribute> >- <xsl:value-of select="current()"/> >- </a> >- </span> >- <xsl:text> </xsl:text> >- </xsl:if> >- <xsl:if test="@code='c'"> >- <span property="datePublished" class="publisher_date"> >- <a> >- <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=copydate:"<xsl:value-of select="str:encode-uri(current(), true())"/>"</xsl:attribute> >- <xsl:value-of select="current()"/> >- </a> >- <xsl:if test="position() != last()"> >- <xsl:text> </xsl:text> >- </xsl:if> >- </span> >- <xsl:text> </xsl:text> >- </xsl:if> >- <xsl:if test="@code='g'"> >- <span property="datePublished" class="publisher_date"> >- <xsl:call-template name="chopPunctuation"> >- <xsl:with-param name="chopString"> >- <xsl:value-of select="current()"/> >- </xsl:with-param> >- </xsl:call-template> >- </span> >- </xsl:if> >+ </xsl:if> >+ <xsl:if test="position() != last()"> >+ <xsl:text> </xsl:text> >+ </xsl:if> > </xsl:for-each> > <xsl:choose><xsl:when test="position()=last()"><xsl:text></xsl:text></xsl:when><xsl:otherwise><xsl:text>; </xsl:text></xsl:otherwise></xsl:choose> > </xsl:for-each> >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 15594
:
128284
|
128369
|
130194
|
130195
|
131363
|
131382
|
131383
|
131384
| 131385