Bugzilla – Attachment 94959 Details for
Bug 23950
Replace MARC21xslt materialtype PNG icons with Font Awesome in the OPAC
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 23950: Replace MARC21xslt materialtype PNG icons with Font Awesome
Bug-23950-Replace-MARC21xslt-materialtype-PNG-icon.patch (text/plain), 11.74 KB, created by
Lucas Gass (lukeg)
on 2019-11-01 22:04:44 UTC
(
hide
)
Description:
Bug 23950: Replace MARC21xslt materialtype PNG icons with Font Awesome
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2019-11-01 22:04:44 UTC
Size:
11.74 KB
patch
obsolete
>From 399fe10cf61c9ec48cb55844ce42f7ac1d4b78c5 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Fri, 1 Nov 2019 20:51:50 +0000 >Subject: [PATCH] Bug 23950: Replace MARC21xslt materialtype PNG icons with > Font Awesome > >--- > .../bootstrap/en/xslt/MARC21slim2OPACDetail.xsl | 65 +++++++++++----------- > .../bootstrap/en/xslt/MARC21slim2OPACResults.xsl | 30 +++++----- > 2 files changed, 47 insertions(+), 48 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >index adbf98c777..3a977f1046 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl >@@ -51,52 +51,52 @@ > <xsl:variable name="controlField008" select="marc:controlfield[@tag=008]"/> > <xsl:variable name="materialTypeCode"> > <xsl:choose> >- <xsl:when test="$leader19='a'">ST</xsl:when> >+ <xsl:when test="$leader19='a'">fa-window-restore</xsl:when> > <xsl:when test="$leader6='a'"> > <xsl:choose> >- <xsl:when test="$leader7='c' or $leader7='d' or $leader7='m'">BK</xsl:when> >- <xsl:when test="$leader7='i' or $leader7='s'">SE</xsl:when> >- <xsl:when test="$leader7='a' or $leader7='b'">AR</xsl:when> >+ <xsl:when test="$leader7='c' or $leader7='d' or $leader7='m'">fa-book</xsl:when> >+ <xsl:when test="$leader7='i' or $leader7='s'">fa-newspaper-o</xsl:when> >+ <xsl:when test="$leader7='a' or $leader7='b'">fa-text-o</xsl:when> > </xsl:choose> > </xsl:when> >- <xsl:when test="$leader6='t'">BK</xsl:when> >- <xsl:when test="$leader6='o' or $leader6='p'">MX</xsl:when> >- <xsl:when test="$leader6='m'">CF</xsl:when> >- <xsl:when test="$leader6='e' or $leader6='f'">MP</xsl:when> >- <xsl:when test="$leader6='g'">VM</xsl:when> >- <xsl:when test="$leader6='k'">PK</xsl:when> >- <xsl:when test="$leader6='r'">OB</xsl:when> >- <xsl:when test="$leader6='i'">SO</xsl:when> >- <xsl:when test="$leader6='j'">MU</xsl:when> >- <xsl:when test="$leader6='c' or $leader6='d'">PR</xsl:when> >+ <xsl:when test="$leader6='t'">fa-book</xsl:when> >+ <xsl:when test="$leader6='o' or $leader6='p'">fa-scale-balance</xsl:when> >+ <xsl:when test="$leader6='m'">fa-laptop</xsl:when> >+ <xsl:when test="$leader6='e' or $leader6='f'">fa-map</xsl:when> >+ <xsl:when test="$leader6='g'">fa-film</xsl:when> >+ <xsl:when test="$leader6='k'">fa-picture-o</xsl:when> >+ <xsl:when test="$leader6='r'">fa-cube</xsl:when> >+ <xsl:when test="$leader6='i'">fa-music</xsl:when> >+ <xsl:when test="$leader6='j'">fa-music</xsl:when> >+ <xsl:when test="$leader6='c' or $leader6='d'">fa-music</xsl:when> > </xsl:choose> > </xsl:variable> > <xsl:variable name="materialTypeLabel"> > <xsl:choose> >- <xsl:when test="$leader19='a'">Set</xsl:when> >+ <xsl:when test="$leader19='a'"> Set</xsl:when> > <xsl:when test="$leader6='a'"> > <xsl:choose> >- <xsl:when test="$leader7='c' or $leader7='d' or $leader7='m'">Text</xsl:when> >+ <xsl:when test="$leader7='c' or $leader7='d' or $leader7='m'"> Text</xsl:when> > <xsl:when test="$leader7='i' or $leader7='s'"> > <xsl:choose> >- <xsl:when test="substring($controlField008,22,1)!='m'">Continuing resource</xsl:when> >- <xsl:otherwise>Series</xsl:otherwise> >+ <xsl:when test="substring($controlField008,22,1)!='m'"> Continuing resource</xsl:when> >+ <xsl:otherwise> Series</xsl:otherwise> > </xsl:choose> > </xsl:when> >- <xsl:when test="$leader7='a' or $leader7='b'">Article</xsl:when> >+ <xsl:when test="$leader7='a' or $leader7='b'"> Article</xsl:when> > </xsl:choose> > </xsl:when> >- <xsl:when test="$leader6='t'">Text</xsl:when> >- <xsl:when test="$leader6='o'">Kit</xsl:when> >- <xsl:when test="$leader6='p'">Mixed materials</xsl:when> >- <xsl:when test="$leader6='m'">Computer file</xsl:when> >- <xsl:when test="$leader6='e' or $leader6='f'">Map</xsl:when> >- <xsl:when test="$leader6='g'">Film</xsl:when> >- <xsl:when test="$leader6='k'">Picture</xsl:when> >- <xsl:when test="$leader6='r'">Object</xsl:when> >- <xsl:when test="$leader6='j'">Music</xsl:when> >- <xsl:when test="$leader6='i'">Sound</xsl:when> >- <xsl:when test="$leader6='c' or $leader6='d'">Score</xsl:when> >+ <xsl:when test="$leader6='t'"> Text</xsl:when> >+ <xsl:when test="$leader6='o'"> Kit</xsl:when> >+ <xsl:when test="$leader6='p'"> Mixed materials</xsl:when> >+ <xsl:when test="$leader6='m'"> Computer file</xsl:when> >+ <xsl:when test="$leader6='e' or $leader6='f'"> Map</xsl:when> >+ <xsl:when test="$leader6='g'"> Film</xsl:when> >+ <xsl:when test="$leader6='k'"> Picture</xsl:when> >+ <xsl:when test="$leader6='r'"> Object</xsl:when> >+ <xsl:when test="$leader6='j'"> Music</xsl:when> >+ <xsl:when test="$leader6='i'"> Sound</xsl:when> >+ <xsl:when test="$leader6='c' or $leader6='d'"> Score</xsl:when> > </xsl:choose> > </xsl:variable> > >@@ -190,10 +190,9 @@ > <xsl:if test="$DisplayOPACiconsXSLT!='0'"> > <xsl:if test="$materialTypeCode!=''"> > <span class="results_summary type"><span class="label">Material type: </span> >- <xsl:element name="img"> >- <xsl:attribute name="src">/opac-tmpl/lib/famfamfam/<xsl:value-of select="$materialTypeCode"/>.png</xsl:attribute> >+ <xsl:element name="i"> > <xsl:attribute name="alt"><xsl:value-of select="$materialTypeLabel"/></xsl:attribute> >- <xsl:attribute name="class">materialtype mt_icon_<xsl:value-of select="$materialTypeCode"/></xsl:attribute> >+ <xsl:attribute name="class">materialtype fa <xsl:value-of select="$materialTypeCode"/></xsl:attribute> > </xsl:element> > <xsl:value-of select="$materialTypeLabel"/> > </span> >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACResults.xsl b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACResults.xsl >index 7c3e3eb8c3..f9ac155771 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACResults.xsl >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACResults.xsl >@@ -662,25 +662,25 @@ > <span class="results_material_type"> > <span class="label">Material type: </span> > <xsl:choose> >- <xsl:when test="$leader19='a'"><img src="/opac-tmpl/lib/famfamfam/ST.png" alt="Set" class="materialtype mt_icon_ST"/> Set</xsl:when> >+ <xsl:when test="$leader19='a'"><i class="materialtype fa fa-window-restore" alt="Set"></i> Set</xsl:when> > <xsl:when test="$leader6='a'"> > <xsl:choose> >- <xsl:when test="$leader7='c' or $leader7='d' or $leader7='m'"><img src="/opac-tmpl/lib/famfamfam/BK.png" alt="Text" class="materialtype mt_icon_BK"/> Text</xsl:when> >- <xsl:when test="$leader7='i' or $leader7='s'"><img src="/opac-tmpl/lib/famfamfam/SE.png" alt="Continuing resource" class="materialtype mt_icon_SE"/> Continuing resource</xsl:when> >- <xsl:when test="$leader7='a' or $leader7='b'"><img src="/opac-tmpl/lib/famfamfam/AR.png" alt="Article" class="materialtype mt_icon_AR"/> Article</xsl:when> >+ <xsl:when test="$leader7='c' or $leader7='d' or $leader7='m'"><i class="materialtype fa fa-book" alt="Text"></i> Text</xsl:when> >+ <xsl:when test="$leader7='i' or $leader7='s'"><i class="materialtype fa fa-newspaper-o" alt="Continuing resource"></i> Continuing resource</xsl:when> >+ <xsl:when test="$leader7='a' or $leader7='b'"><i class="materialtype fa fa-text-o" alt="Article"></i> Article</xsl:when> > </xsl:choose> > </xsl:when> >- <xsl:when test="$leader6='t'"><img src="/opac-tmpl/lib/famfamfam/BK.png" alt="Text" class="materialtype mt_icon_BK"/> Text</xsl:when> >- <xsl:when test="$leader6='o'"><img src="/opac-tmpl/lib/famfamfam/MM.png" alt="Kit" class="materialtype mt_icon_MM"/> Kit</xsl:when> >- <xsl:when test="$leader6='p'"><img src="/opac-tmpl/lib/famfamfam/MM.png" alt="Mixed materials" class="materialtype mt_icon_MM"/>Mixed materials</xsl:when> >- <xsl:when test="$leader6='m'"><img src="/opac-tmpl/lib/famfamfam/CF.png" alt="Computer file" class="materialtype mt_icon_CF"/> Computer file</xsl:when> >- <xsl:when test="$leader6='e' or $leader6='f'"><img src="/opac-tmpl/lib/famfamfam/MP.png" alt="Map" class="materialtype mt_icon_MP"/> Map</xsl:when> >- <xsl:when test="$leader6='g'"><img src="/opac-tmpl/lib/famfamfam/VM.png" alt="Film" class="materialtype mt_icon_VM"/> Film</xsl:when> >- <xsl:when test="$leader6='k'"><img src="/opac-tmpl/lib/famfamfam/GR.png" alt="Picture" class="materialtype mt_icon_GR"/> Picture</xsl:when> >- <xsl:when test="$leader6='r'"><img src="/opac-tmpl/lib/famfamfam/OB.png" alt="Object" class="materialtype mt_icon_OB"/> Object</xsl:when> >- <xsl:when test="$leader6='c' or $leader6='d'"><img src="/opac-tmpl/lib/famfamfam/PR.png" alt="Score" class="materialtype mt_icon_PR"/> Score</xsl:when> >- <xsl:when test="$leader6='i'"><img src="/opac-tmpl/lib/famfamfam/MU.png" alt="Sound" class="materialtype mt_icon_MU"/> Sound</xsl:when> >- <xsl:when test="$leader6='j'"><img src="/opac-tmpl/lib/famfamfam/PR.png" alt="Music" class="materialtype mt_icon_PR"/> Music</xsl:when> >+ <xsl:when test="$leader6='t'"><i class="materialtype fa fa-book" alt="Text"></i> Text</xsl:when> >+ <xsl:when test="$leader6='o'"><i class="materialtype fa fa-balance-scale" alt="Kit"></i> Kit</xsl:when> >+ <xsl:when test="$leader6='p'"><i class="materialtypl fa fa-object-group" alt="Mixed materials"></i> Mixed materials</xsl:when> >+ <xsl:when test="$leader6='m'"><i class="materialtype fa fa-laptop" alt="Computer file"></i> Computer file</xsl:when> >+ <xsl:when test="$leader6='e' or $leader6='f'"><i class="materialtype fa fa-map" alt="Map"></i> Map</xsl:when> >+ <xsl:when test="$leader6='g'"><i class="materialtype fa fa-film" alt="Film"></i> Film</xsl:when> >+ <xsl:when test="$leader6='k'"><i class="materialtype fa fa-picture-o" alt="Picture"></i> Picture</xsl:when> >+ <xsl:when test="$leader6='r'"><i class="materialtype fa fa-cube" alt="Object"></i> Object</xsl:when> >+ <xsl:when test="$leader6='c' or $leader6='d'"><i class="materialtype fa fa-music" alt="Score"></i> Score</xsl:when> >+ <xsl:when test="$leader6='i'"><i class="materialtype fa fa-music" alt="Sound"></i> Sound</xsl:when> >+ <xsl:when test="$leader6='j'"><i class="materialtype fa fa-music" alt="Music"></i> Music</xsl:when> > </xsl:choose> > </span> > </xsl:if> >-- >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 23950
: 94959 |
94970