Bugzilla – Attachment 110307 Details for
Bug 16728
Add MARC21 777 - Issued with entry to staff and OPAC detail pages
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 16728: Add MARC21 777 - Issued with entry to staff and OPAC detail pages
Bug-16728-Add-MARC21-777---Issued-with-entry-to-st.patch (text/plain), 7.65 KB, created by
Katrin Fischer
on 2020-09-17 23:27:14 UTC
(
hide
)
Description:
Bug 16728: Add MARC21 777 - Issued with entry to staff and OPAC detail pages
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2020-09-17 23:27:14 UTC
Size:
7.65 KB
patch
obsolete
>From a8160a651d68bfba4dae558d93374ad3672cd061 Mon Sep 17 00:00:00 2001 >From: Katrin Fischer <katrin.fischer.83@web.de> >Date: Thu, 17 Sep 2020 12:13:36 +0000 >Subject: [PATCH] Bug 16728: Add MARC21 777 - Issued with entry to staff and > OPAC detail pages > >This adds the 777 - Issued with entry to the staff and OPAC detail pages. >It's built using the template for 773 with minor adjustments. > >To test: >- Apply patch >- Catalog several 777 fields in one or more of your records > - When using 1st indicator = 1, the note won't display > - When using 2nd indicator empty, label will be "Issued with:" > - When using 2nd indicator 8, the label will be drawn from $i if present > - When $w and UseControlNumber pref is used, the link will be built using $w > - In all other cases the title form $t will be used for the link >- Verify the display is correct > >Examples for 777 can be found in the LOC MARC21 documentation: >http://www.loc.gov/marc/bibliographic/bd777.html > >Note: Because the label depends on the 2nd indicator, the label is repeated for every >777 on a record. >--- > .../prog/en/xslt/MARC21slim2intranetDetail.xsl | 48 ++++++++++++++++++++++ > .../bootstrap/en/xslt/MARC21slim2OPACDetail.xsl | 48 ++++++++++++++++++++++ > 2 files changed, 96 insertions(+) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >index 16f727a0e1..3b52773766 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >+++ b/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl >@@ -918,6 +918,54 @@ > </span> > </xsl:if> > >+<!-- MARC21 777 - Issued With Entry --> >+ <xsl:if test="marc:datafield[@tag=777]"> >+ <xsl:for-each select="marc:datafield[@tag=777]"> >+ <xsl:if test="@ind1 != 1"> >+ <span class="results_summary issued_with"> >+ <span class="label"> >+ <xsl:choose> >+ <xsl:when test="@ind2=8 and marc:subfield[@code='i']"> >+ <xsl:value-of select="marc:subfield[@code='i']"/> >+ </xsl:when> >+ <xsl:otherwise> >+ <xsl:text>Issued with:</xsl:text> >+ </xsl:otherwise> >+ </xsl:choose> >+ <xsl:text> </xsl:text> >+ </span> >+ <xsl:variable name="f777"> >+ <xsl:call-template name="chopPunctuation"> >+ <xsl:with-param name="chopString"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">a_t</xsl:with-param> >+ </xsl:call-template> >+ </xsl:with-param> >+ </xsl:call-template> >+ </xsl:variable> >+ <xsl:choose> >+ <xsl:when test="$UseControlNumber = '1' and marc:subfield[@code='w']"> >+ <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=control-number:<xsl:call-template name="extractControlNumber"><xsl:with-param name="subfieldW" select="marc:subfield[@code='w']"/></xsl:call-template></xsl:attribute> >+ <xsl:value-of select="translate($f777, '()', '')"/> >+ </a> >+ </xsl:when> >+ <xsl:otherwise> >+ <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(marc:subfield[@code='t'], true())"/></xsl:attribute> >+ <xsl:value-of select="$f777"/> >+ </a> >+ </xsl:otherwise> >+ </xsl:choose> >+ <xsl:if test="marc:subfield[@code='g']"> >+ <xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/> >+ </xsl:if> >+ </span> >+ <xsl:if test="marc:subfield[@code='n']"> >+ <xsl:text> </xsl:text><span class="results_summary in_note"><xsl:value-of select="marc:subfield[@code='n']"/></span> >+ </xsl:if> >+ </xsl:if> >+ </xsl:for-each> >+ </xsl:if> >+ > <!-- DDC classification --> > <xsl:if test="marc:datafield[@tag=082]"> > <span class="results_summary ddc"> >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >index f507ea428e..54ad287a39 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >@@ -970,6 +970,54 @@ > </span> > </xsl:if> > >+<!-- MARC21 777 - Issued With Entry --> >+ <xsl:if test="marc:datafield[@tag=777]"> >+ <xsl:for-each select="marc:datafield[@tag=777]"> >+ <xsl:if test="@ind1 != 1"> >+ <span class="results_summary issued_with"> >+ <span class="label"> >+ <xsl:choose> >+ <xsl:when test="@ind2=8 and marc:subfield[@code='i']"> >+ <xsl:value-of select="marc:subfield[@code='i']"/> >+ </xsl:when> >+ <xsl:otherwise> >+ <xsl:text>Issued with:</xsl:text> >+ </xsl:otherwise> >+ </xsl:choose> >+ <xsl:text> </xsl:text> >+ </span> >+ <xsl:variable name="f777"> >+ <xsl:call-template name="chopPunctuation"> >+ <xsl:with-param name="chopString"> >+ <xsl:call-template name="subfieldSelect"> >+ <xsl:with-param name="codes">a_t</xsl:with-param> >+ </xsl:call-template> >+ </xsl:with-param> >+ </xsl:call-template> >+ </xsl:variable> >+ <xsl:choose> >+ <xsl:when test="$UseControlNumber = '1' and marc:subfield[@code='w']"> >+ <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=control-number:<xsl:call-template name="extractControlNumber"><xsl:with-param name="subfieldW" select="marc:subfield[@code='w']"/></xsl:call-template></xsl:attribute> >+ <xsl:value-of select="translate($f777, '()', '')"/> >+ </a> >+ </xsl:when> >+ <xsl:otherwise> >+ <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(marc:subfield[@code='t'], true())"/></xsl:attribute> >+ <xsl:value-of select="$f777"/> >+ </a> >+ </xsl:otherwise> >+ </xsl:choose> >+ <xsl:if test="marc:subfield[@code='g']"> >+ <xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/> >+ </xsl:if> >+ </span> >+ <xsl:if test="marc:subfield[@code='n']"> >+ <xsl:text> </xsl:text><span class="results_summary in_note"><xsl:value-of select="marc:subfield[@code='n']"/></span> >+ </xsl:if> >+ </xsl:if> >+ </xsl:for-each> >+ </xsl:if> >+ > <!-- DDC classification --> > <xsl:if test="marc:datafield[@tag=082]"> > <span class="results_summary ddc"> >-- >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 16728
:
110307
|
110416
|
111246