From affd3f0eceba42ec7c92706452a892823eed39e0 Mon Sep 17 00:00:00 2001 From: Mason James Date: Tue, 1 May 2018 13:24:37 +1200 Subject: [PATCH] Bug 20686: OPAC shows 'Login to OverDrive account' with 'OverDriveCirculation' syspref disabled MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit ps: you will need an active and working overdrive account to test this patch 1/ prepare a koha with overdrive sysprefs set and working (OverDriveLibraryID,OverDriveClientKey,OverDriveClientSecret) 2/ set OverDriveCirculation syspref to 'disable' 3/ do an opac search, note the 'Login to OverDrive account' message is incorrectly displayed see pic 1 4/ apply patch 5/ do an opac search, note the 'Login to OverDrive account' message is no longer displayed (good) see pic 2 Can confirm that bug is replicable and patch applies and functions as described. Signed-off-by: Dilan Johnpullé Signed-off-by: Tomas Cohen Arazi Signed-off-by: Jonathan Druart --- .../opac-tmpl/bootstrap/en/modules/opac-overdrive-search.tt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-overdrive-search.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-overdrive-search.tt index 32d2734b80..a96715cee8 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-overdrive-search.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-overdrive-search.tt @@ -187,7 +187,7 @@ $( document ).ready( function() { [% IF ( overdrive_error ) %] KOHA.OverDriveCirculation.display_error("#breadcrumbs", "[% overdrive_error.dquote %]"); [% END %] - [% IF ( loggedinusername ) %] + [% IF ( loggedinusername and OverDriveCirculation ) %] KOHA.OverDriveCirculation.with_account_details("#breadcrumbs", function() { search( 0 ); }); -- 2.39.5