Bugzilla – Attachment 61793 Details for
Bug 18369
Broken title link in UNIMARC catalog search results table
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18369: Broken title link in UNIMARC catalog search results table
Bug-18369-Broken-title-link-in-UNIMARC-catalog-searc.patch (text/plain), 3.42 KB, created by
Oleg Vasylenko
on 2017-04-03 11:33:16 UTC
(
hide
)
Description:
Bug 18369: Broken title link in UNIMARC catalog search results table
Filename:
MIME Type:
Creator:
Oleg Vasylenko
Created:
2017-04-03 11:33:16 UTC
Size:
3.42 KB
patch
obsolete
>From 8de2b6588f84def555fc377f3fa6d5fa94c418c1 Mon Sep 17 00:00:00 2001 >From: Oleg Vasylenko <synapse.ova@gmail.com> >Date: Mon, 3 Apr 2017 14:16:51 +0300 >Subject: [PATCH 2/2] Bug 18369 - Broken title link in UNIMARC catalog search > results table >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >In staff client, «Search the catalog» returns a table, where biblio title has a broken link (biblionumber is absent), yet other links works good (Holds, Edit Record, Edit items, OPAC view) > >Steps to Reproduce: > In staff client, search the catalog (Cataloging â «Search the catalog» (/cgi-bin/koha/catalogue/search.pl)) > >Actual Results: >Title of the biblio has a link, that doesn't have biblionumber > >Expected Results: >Title of the biblio should have a link with a proper biblionumber at the end > >Additional Information: >Each biblio in the results table is shown by XSL transformation of MARC data. XSL (\intranet-tmpl\prog\en\xslt\UNIMARCslim2intranetResults.xsl) prepares a link, and adds a biblionumber, that it expects to get from controlfield 001. But since this field could be either empty or contain something different than biblionumber (see https://lists.katipo.co.nz/public/koha/2015-September/043652.html), it is better to pass the biblionumber to this script. >This script is already receiving sysprefs (that is not according to marcxml standart), so I suggest to pass the biblionumber the same way. >--- > C4/XSLT.pm | 3 ++- > koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetResults.xsl | 2 +- > 2 files changed, 3 insertions(+), 2 deletions(-) > >diff --git a/C4/XSLT.pm b/C4/XSLT.pm >index b757f8ff8b..83a525f9ee 100644 >--- a/C4/XSLT.pm >+++ b/C4/XSLT.pm >@@ -192,6 +192,7 @@ sub XSLTParse4Display { > $sysxml ||= C4::Context->preference($xslsyspref); > $xslfilename ||= C4::Context->preference($xslsyspref); > $lang ||= C4::Languages::getlanguage(); >+ my $kohavars = "<koha>\n<biblionumber>$biblionumber</biblionumber>\n</koha>\n"; > > if ( $xslfilename =~ /^\s*"?default"?\s*$/i ) { > my $htdocs; >@@ -242,7 +243,7 @@ sub XSLTParse4Display { > my $itemsxml = buildKohaItemsNamespace($biblionumber, $hidden_items); > my $xmlrecord = $record->as_xml(C4::Context->preference('marcflavour')); > >- $xmlrecord =~ s/\<\/record\>/$itemsxml$sysxml\<\/record\>/; >+ $xmlrecord =~ s/\<\/record\>/$itemsxml$sysxml$kohavars\<\/record\>/; > if ($fixamps) { # We need to correct the HTML entities that Zebra outputs > $xmlrecord =~ s/\&amp;/\&/g; > $xmlrecord =~ s/\&\;lt\;/\<\;/g; >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetResults.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetResults.xsl >index 3e30890cd5..8c6ba6eef2 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetResults.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetResults.xsl >@@ -22,7 +22,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:controlfield[@tag=001]"/> >+ <xsl:variable name="biblionumber" select="marc:koha/marc:biblionumber"/> > <xsl:variable name="isbn" select="marc:datafield[@tag=010]/marc:subfield[@code='a']"/> > > <xsl:if test="marc:datafield[@tag=200]"> >-- >2.11.0.windows.1 >
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 18369
: 61793