Bugzilla – Attachment 100213 Details for
Bug 22969
fix biblionumber on 001 in UNIMARC XSLT
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 22969: fix biblionumber on 001 in UNIMARC XSLT
Bug-22969-fix-biblionumber-on-001-in-UNIMARC-XSLT.patch (text/plain), 4.58 KB, created by
Marcel de Rooy
on 2020-03-06 07:48:02 UTC
(
hide
)
Description:
Bug 22969: fix biblionumber on 001 in UNIMARC XSLT
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2020-03-06 07:48:02 UTC
Size:
4.58 KB
patch
obsolete
>From 71d0f4c6b454ee522d0db45b6bf17187e6b1cbd1 Mon Sep 17 00:00:00 2001 >From: Fridolin Somers <fridolin.somers@biblibre.com> >Date: Thu, 23 May 2019 07:55:15 +0200 >Subject: [PATCH] Bug 22969: fix biblionumber on 001 in UNIMARC XSLT >Content-Type: text/plain; charset=utf-8 > >In UNIMARC default configuration the 001 is linked to biblio.biblionumber. >In some XSLT files, 090$a is used. >This is by default biblioitems.biblionumber so it usually works but it may not be the same and var biblionumber is used to create hyperlinks to record detail page. > >Test plan : >1) Use UNIMARC database >2) Set default in all XSLT system preferences >3) At OPAC, perform a search and click on a result >4) Check displayed page shows the correct biblio record >5) Same at intranet > >Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> >Tested on clean UNIMARC install. >Before insert new records: "alter table biblioitems AUTO_INCREMENT = 5" >Added two records, with result: >+--------------+------------------+ >| biblionumber | biblioitemnumber | >+--------------+------------------+ >| 1 | 5 | >| 2 | 6 | >+--------------+------------------+ >Without patch, OPAC results shows for first record > http://opac/cgi-bin/koha/opac-detail.pl?biblionumber=5, Wrong! >with patch result is correct > >Works, no errors > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl | 2 +- > koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl | 2 +- > koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACResults.xsl | 6 ++---- > 3 files changed, 4 insertions(+), 6 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl >index 361b88c10c..5f6e2b1782 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetDetail.xsl >@@ -19,7 +19,7 @@ > <xsl:variable name="leader" select="marc:leader"/> > <xsl:variable name="leader6" select="substring($leader,7,1)"/> > <xsl:variable name="leader7" select="substring($leader,8,1)"/> >- <xsl:variable name="biblionumber" select="marc:datafield[@tag=090]/marc:subfield[@code='a']"/> >+ <xsl:variable name="biblionumber" select="marc:controlfield[@tag=001]"/> > > > <xsl:if test="marc:datafield[@tag=200]"> >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl >index 55fd2293ad..e5afad7c67 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACDetail.xsl >@@ -18,7 +18,7 @@ > <xsl:variable name="leader" select="marc:leader"/> > <xsl:variable name="leader6" select="substring($leader,7,1)"/> > <xsl:variable name="leader7" select="substring($leader,8,1)"/> >- <xsl:variable name="biblionumber" select="marc:datafield[@tag=090]/marc:subfield[@code='a']"/> >+ <xsl:variable name="biblionumber" select="marc:controlfield[@tag=001]"/> > <xsl:variable name="DisplayOPACiconsXSLT" select="marc:sysprefs/marc:syspref[@name='DisplayOPACiconsXSLT']"/> > <xsl:variable name="OPACURLOpenInNewWindow" select="marc:sysprefs/marc:syspref[@name='OPACURLOpenInNewWindow']"/> > <xsl:variable name="URLLinkText" select="marc:sysprefs/marc:syspref[@name='URLLinkText']"/> >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACResults.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACResults.xsl >index 2174d5d935..3279def752 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACResults.xsl >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACResults.xsl >@@ -23,10 +23,8 @@ > <xsl:variable name="leader" select="marc:leader"/> > <xsl:variable name="leader6" select="substring($leader,7,1)"/> > <xsl:variable name="leader7" select="substring($leader,8,1)"/> >- <xsl:variable name="biblionumber" >- select="marc:datafield[@tag=090]/marc:subfield[@code='a']"/> >- <xsl:variable name="isbn" >- select="marc:datafield[@tag=010]/marc:subfield[@code='a']"/> >+ <xsl:variable name="biblionumber" select="marc:controlfield[@tag=001]"/> >+ <xsl:variable name="isbn" select="marc:datafield[@tag=010]/marc:subfield[@code='a']"/> > <xsl:variable name="OPACResultsLibrary" select="marc:sysprefs/marc:syspref[@name='OPACResultsLibrary']"/> > <xsl:variable name="BiblioDefaultView" select="marc:sysprefs/marc:syspref[@name='BiblioDefaultView']"/> > <xsl:variable name="hidelostitems" select="marc:sysprefs/marc:syspref[@name='hidelostitems']"/> >-- >2.11.0
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 22969
:
89994
|
100158
| 100213