Bugzilla – Attachment 49582 Details for
Bug 14304
RDA: Display link in XSLT for 264 field to reflect Zebra indexing
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14304: RDA: Intranet display link in XSLT for 264 field to reflect Zebra indexing
Bug-14304-RDA-Intranet-display-link-in-XSLT-for-26.patch (text/plain), 6.39 KB, created by
Marcel de Rooy
on 2016-03-25 09:25:43 UTC
(
hide
)
Description:
Bug 14304: RDA: Intranet display link in XSLT for 264 field to reflect Zebra indexing
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2016-03-25 09:25:43 UTC
Size:
6.39 KB
patch
obsolete
>From 2eafb9d56ec8805877af03e4b47f6c7176f3cd7f Mon Sep 17 00:00:00 2001 >From: Hector Castro <hector.hecaxmmx@gmail.com> >Date: Fri, 5 Feb 2016 00:40:51 -0600 >Subject: [PATCH] Bug 14304: RDA: Intranet display link in XSLT for 264 field > to reflect Zebra indexing >Content-Type: text/plain; charset=utf-8 > >This patch add display link in XSLT for 264 for bug 14198 and reflect the >Zebra indexing 'Provider' in detail page for Intranet. > >Test plan >1) Update zebra index if no Provider: index exist >2) Do a search by Provider: >3) Goto detail page for a record with 264 >4) Look that there no display link for 264 field. >5) Apply the patch >6) Reload the page, notice about the link, click the link an confirm > the new index Provider works fine >7) Test with multiple records with 260 and 264, if you prefer follow test plan > for bug 14734 >8) Access an RCAA2 record just with 260 field >9) Notice that 260 has been updated with Provider index too. >NOTE: The intention of Provider index -according with documentation- is >to collect multiples fields including 260, 264, 270, and 257 > >Sponsored-by: Universidad de El Salvador > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > .../prog/en/xslt/MARC21slim2intranetDetail.xsl | 6 ++- > .../intranet-tmpl/prog/en/xslt/MARC21slimUtils.xsl | 40 +++++++++++++++++++- > 2 files changed, 42 insertions(+), 4 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >index d42e75a..d3b4997 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >@@ -314,7 +314,9 @@ > <!-- Publisher info and RDA related info from tags 260, 264 --> > <xsl:choose> > <xsl:when test="marc:datafield[@tag=264]"> >- <xsl:call-template name="showRDAtag264"/> >+ <xsl:call-template name="showRDAtag264"> >+ <xsl:with-param name="show_url">1</xsl:with-param> >+ </xsl:call-template> > </xsl:when> > <xsl:when test="marc:datafield[@tag=260]"> > <span class="results_summary publisher"><span class="label">Publisher: </span> >@@ -326,7 +328,7 @@ > </xsl:if> > <xsl:text> </xsl:text> > <xsl:if test="marc:subfield[@code='b']"> >- <a href="/cgi-bin/koha/catalogue/search.pl?q=pb:{marc:subfield[@code='b']}"> >+ <a href="/cgi-bin/koha/catalogue/search.pl?q=Provider:{marc:subfield[@code='b']}"> > <xsl:call-template name="subfieldSelect"> > <xsl:with-param name="codes">b</xsl:with-param> > </xsl:call-template> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slimUtils.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slimUtils.xsl >index 9d12643..192107b 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slimUtils.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slimUtils.xsl >@@ -218,11 +218,13 @@ > The preferred tag is saved in the fav variable and passed to a > helper named-template --> > <!-- Amended to show all 264 fields (filtered by ind1=3 if ind1=3 is present in the record) --> >+ <xsl:param name="show_url"/> > <xsl:choose> > <xsl:when test="marc:datafield[@tag=264 and @ind1=3]"> > <xsl:for-each select="marc:datafield[@tag=264 and @ind1=3]"> > <xsl:call-template name="showRDAtag264helper"> > <xsl:with-param name="field" select="."/> >+ <xsl:with-param name="url" select="$show_url"/> > </xsl:call-template> > </xsl:for-each> > </xsl:when> >@@ -230,6 +232,7 @@ > <xsl:for-each select="marc:datafield[@tag=264]"> > <xsl:call-template name="showRDAtag264helper"> > <xsl:with-param name="field" select="."/> >+ <xsl:with-param name="url" select="$show_url"/> > </xsl:call-template> > </xsl:for-each> > </xsl:otherwise> >@@ -237,6 +240,7 @@ > </xsl:template> > <xsl:template name="showRDAtag264helper"> > <xsl:param name="field"/> >+ <xsl:param name="url"/> > <xsl:variable name="ind2" select="$field/@ind2"/> > <span class="results_summary"> > <xsl:choose> >@@ -256,9 +260,41 @@ > <span class="label">Copyright date: </span> > </xsl:when> > </xsl:choose> >- <xsl:call-template name="subfieldSelect"> >- <xsl:with-param name="codes">abc</xsl:with-param> >+ >+ <xsl:if test="$field/marc:subfield[@code='a']"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">a</xsl:with-param> >+ </xsl:call-template> >+ </xsl:if> >+ <xsl:text> </xsl:text> >+ >+ <xsl:choose> >+ <xsl:when test="$url='1'"> >+ <xsl:if test="$field/marc:subfield[@code='b']"> >+ <a href="/cgi-bin/koha/catalogue/search.pl?q=Provider:{$field/marc:subfield[@code='b']}"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">b</xsl:with-param> >+ </xsl:call-template> >+ </a> >+ </xsl:if> >+ </xsl:when> >+ <xsl:otherwise> >+ <xsl:if test="$field/marc:subfield[@code='b']"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">b</xsl:with-param> >+ </xsl:call-template> >+ </xsl:if> >+ </xsl:otherwise> >+ </xsl:choose> >+ <xsl:text> </xsl:text> >+ <xsl:call-template name="chopPunctuation"> >+ <xsl:with-param name="chopString"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">c</xsl:with-param> >+ </xsl:call-template> >+ </xsl:with-param> > </xsl:call-template> >+ > </span> > </xsl:template> > >-- >1.7.10.4
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 14304
:
42178
|
47632
|
47677
|
47700
|
48481
|
48482
| 49582 |
49583