Bugzilla – Attachment 40020 Details for
Bug 14054
246 XSLT Improvements
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14054 - 246 XSLT Improvements
Bug-14054---246-XSLT-Improvements.patch (text/plain), 7.50 KB, created by
Winona Salesky
on 2015-06-09 14:19:47 UTC
(
hide
)
Description:
Bug 14054 - 246 XSLT Improvements
Filename:
MIME Type:
Creator:
Winona Salesky
Created:
2015-06-09 14:19:47 UTC
Size:
7.50 KB
patch
obsolete
>From cf1b40520cba559d5640040f0819026476a1e23b Mon Sep 17 00:00:00 2001 >From: Winona Salesky <wsalesky@gmail.com> >Date: Tue, 9 Jun 2015 10:18:05 -0400 >Subject: [PATCH] Bug 14054 - 246 XSLT Improvements > >Adds other title type based on ind2 value. ind2 overridden by $i value. >--- > .../prog/en/xslt/MARC21slim2intranetDetail.xsl | 42 +++++++++++++------ > .../bootstrap/en/xslt/MARC21slim2OPACDetail.xsl | 48 ++++++++++++++-------- > 2 files changed, 61 insertions(+), 29 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >index d077e35..378dafa 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >@@ -476,20 +476,36 @@ > </xsl:if> > > <xsl:if test="marc:datafield[@tag=246]"> >- <span class="results_summary other_title"><span class="label">Other title: </span> >- <xsl:for-each select="marc:datafield[@tag=246]"> >- <xsl:call-template name="chopPunctuation"> >- <xsl:with-param name="chopString"> >- <xsl:call-template name="subfieldSelect"> >- <xsl:with-param name="codes">iabhfgnp</xsl:with-param> >+ <span class="results_summary other_title"><span class="label">Other title: </span> >+ <xsl:for-each select="marc:datafield[@tag=246]"> >+ <xsl:call-template name="chopPunctuation"> >+ <xsl:with-param name="chopString"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">abhfgnp</xsl:with-param> >+ </xsl:call-template> >+ </xsl:with-param> > </xsl:call-template> >- </xsl:with-param> >- </xsl:call-template> >- <!-- #13386 added separator | --> >- <xsl:choose><xsl:when test="position()=last()"><xsl:text>.</xsl:text></xsl:when><xsl:otherwise><span class="separator"><xsl:text> | </xsl:text></span></xsl:otherwise></xsl:choose> >- </xsl:for-each> >- </span> >- </xsl:if> >+ <xsl:if test="@ind1=1 and not(marc:subfield[@code='i'])"> >+ <xsl:choose> >+ <xsl:when test="@ind2=0"> [Portion of title]</xsl:when> >+ <xsl:when test="@ind2=1"> [Parallel title]</xsl:when> >+ <xsl:when test="@ind2=2"> [Distinctive title]</xsl:when> >+ <xsl:when test="@ind2=3"> [Other title]</xsl:when> >+ <xsl:when test="@ind2=4"> [Cover title]</xsl:when> >+ <xsl:when test="@ind2=5"> [Added title page title]</xsl:when> >+ <xsl:when test="@ind2=6"> [Caption title]</xsl:when> >+ <xsl:when test="@ind2=7"> [Running title]</xsl:when> >+ <xsl:when test="@ind2=8"> [Spine title]</xsl:when> >+ </xsl:choose> >+ </xsl:if> >+ <xsl:if test="marc:subfield[@code='i']"> >+ <xsl:value-of select="concat(' [',marc:subfield[@code='i'],']')"/> >+ </xsl:if> >+ <!-- #13386 added separator | --> >+ <xsl:choose><xsl:when test="position()=last()"><xsl:text>.</xsl:text></xsl:when><xsl:otherwise><span class="separator"><xsl:text> | </xsl:text></span></xsl:otherwise></xsl:choose> >+ </xsl:for-each> >+ </span> >+ </xsl:if> > > <xsl:if test="marc:datafield[@tag=242]"> > <span class="results_summary translated_title"><span class="label">Title translated: </span> >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >index 8b7d559..e4a19d2 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >@@ -508,23 +508,39 @@ > </xsl:call-template> > </xsl:if> > >- <xsl:if test="marc:datafield[@tag=246]"> >- <span class="results_summary other_title"><span class="label">Other title: </span> >- <xsl:for-each select="marc:datafield[@tag=246]"> >- <span property="alternateName"> >- <xsl:call-template name="chopPunctuation"> >- <xsl:with-param name="chopString"> >- <xsl:call-template name="subfieldSelect"> >- <xsl:with-param name="codes">iabhfgnp</xsl:with-param> >- </xsl:call-template> >- </xsl:with-param> >- </xsl:call-template> >+ <xsl:if test="marc:datafield[@tag=246]"> >+ <span class="results_summary other_title"><span class="label">Other title: </span> >+ <xsl:for-each select="marc:datafield[@tag=246]"> >+ <span property="alternateName"> >+ <xsl:call-template name="chopPunctuation"> >+ <xsl:with-param name="chopString"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">abhfgnp</xsl:with-param> >+ </xsl:call-template> >+ </xsl:with-param> >+ </xsl:call-template> >+ <xsl:if test="@ind1=1 and not(marc:subfield[@code='i'])"> >+ <xsl:choose> >+ <xsl:when test="@ind2=0"> [Portion of title]</xsl:when> >+ <xsl:when test="@ind2=1"> [Parallel title]</xsl:when> >+ <xsl:when test="@ind2=2"> [Distinctive title]</xsl:when> >+ <xsl:when test="@ind2=3"> [Other title]</xsl:when> >+ <xsl:when test="@ind2=4"> [Cover title]</xsl:when> >+ <xsl:when test="@ind2=5"> [Added title page title]</xsl:when> >+ <xsl:when test="@ind2=6"> [Caption title]</xsl:when> >+ <xsl:when test="@ind2=7"> [Running title]</xsl:when> >+ <xsl:when test="@ind2=8"> [Spine title]</xsl:when> >+ </xsl:choose> >+ </xsl:if> >+ <xsl:if test="marc:subfield[@code='i']"> >+ <xsl:value-of select="concat(' [',marc:subfield[@code='i'],']')"/> >+ </xsl:if> >+ </span> >+ <!-- #13386 added separator | --> >+ <xsl:choose><xsl:when test="position()=last()"><xsl:text>.</xsl:text></xsl:when><xsl:otherwise><span class="separator"><xsl:text> | </xsl:text></span></xsl:otherwise></xsl:choose> >+ </xsl:for-each> > </span> >- <!-- #13386 added separator | --> >- <xsl:choose><xsl:when test="position()=last()"><xsl:text>.</xsl:text></xsl:when><xsl:otherwise><span class="separator"><xsl:text> | </xsl:text></span></xsl:otherwise></xsl:choose> >- </xsl:for-each> >- </span> >- </xsl:if> >+ </xsl:if> > > > <xsl:if test="marc:datafield[@tag=242]"> >-- >2.3.2 (Apple Git-55)
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 14054
:
39831
|
40020
|
40212
|
42802