From 03172a4f58bb7d706552ea59ad5f330631f92253 Mon Sep 17 00:00:00 2001
From: Aleisha Amohia
Date: Tue, 13 Jun 2017 22:15:13 +0000
Subject: [PATCH] Bug 18798: Use Koha.Preference in OPAC Reading Record
This patch uses the Koha.Preference plugin method for the following
sysprefs:
- OPACMySummaryHTML
- OPACAmazonCoverImages
- SyndeticsEnabled
- SyndeticsCoverImages
- SyndeticsClientCode
- GoogleJackets
- BakerTaylorEnabled (Bug 17896)
- BakerTaylorBookstoreURL (Bug 17896)
To test, apply the patch from Bug 17896 and confirm that enabling and
disabling the above sysprefs does not break anything.
Sponsored-by: Catalyst IT
Signed-off-by: Owen Leonard
I'm not able to test Syndetics and BakerTaylor, but everything else
works correctly.
---
.../bootstrap/en/modules/opac-readingrecord.tt | 19 ++++++++++---------
opac/opac-readingrecord.pl | 7 -------
2 files changed, 10 insertions(+), 16 deletions(-)
diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-readingrecord.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-readingrecord.tt
index d03d5185..741fad6 100644
--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-readingrecord.tt
+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-readingrecord.tt
@@ -63,7 +63,7 @@
[% END %]
- [% IF Koha.Preference( 'OnSiteCheckouts' ) == 1 %]
+ [% IF ( Koha.Preference( 'OnSiteCheckouts' ) == 1 ) %]
- All
@@ -81,7 +81,7 @@
Item type |
Call no. |
Date |
- [% IF ( OPACMySummaryHTML ) %]
+ [% IF ( Koha.Preference('OPACMySummaryHTML') ) %]
Links |
[% END %]
@@ -106,7 +106,8 @@
[% END %]
[% END %]
- [% IF OPACAmazonCoverImages %]
+
+ [% IF ( Koha.Preference('OPACAmazonCoverImages') ) %]
[% IF issue.normalized_isbn %]
[% ELSE %]
@@ -131,13 +132,13 @@
[% END %]
[% END %]
- [% IF SyndeticsEnabled && SyndeticsCoverImages %]
-
+ [% IF ( Koha.Preference('SyndeticsEnabled') && Koha.Preference('SyndeticsCoverImages') ) %]
+
[% END %]
- [% IF issue.BiblioDefaultViewmarc %]
- [% issue.title | html %] [% IF issue.subtitle %][% FOREACH subtitl IN issue.subtitle %][% subtitl.subfield | html %][% END %][% END %]
+ [% IF issue.BiblioDefaultViewmarc %]
+ [% issue.title |html %] [% IF issue.subtitle %][% FOREACH subtitl IN issue.subtitle %][% subtitl.subfield | html %][% END %][% END %]
[% ELSIF issue.BiblioDefaultViewisbd %]
[% issue.title | html %] [% IF issue.subtitle %][% FOREACH subtitl IN issue.subtitle %][% subtitl.subfield | html %][% END %][% END %]
[% ELSE %]
@@ -165,7 +166,7 @@
(Checked out)
[% END %]
|
- [% IF OPACMySummaryHTML %]
+ [% IF ( Koha.Preference('OPACMySummaryHTML') ) %]
[% issue.MySummaryHTML | $raw %] |
[% END %]
@@ -190,7 +191,7 @@