From c2324f544140ea48443eb3d72f0d58c49d60ab5c Mon Sep 17 00:00:00 2001 From: Aleisha Amohia Date: Tue, 28 Sep 2021 15:24:48 +1300 Subject: [PATCH] Bug 14242: (follow-up) Hide autofil when syspref disabled, clear ISBN Signed-off-by: Owen Leonard Signed-off-by: Katrin Fischer Signed-off-by: Katrin Fischer --- koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt | 2 +- koha-tmpl/opac-tmpl/bootstrap/js/autofill.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt index 14429f3e34..f2920b3089 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt @@ -497,7 +497,7 @@ [% INCLUDE 'opac-bottom.inc' %] [% BLOCK jsinclude %] -[% IF ( Koha.Preference("OPACSuggestionAutoFill") ) %] +[% IF ( Koha.Preference("OPACSuggestionAutoFill") != 'no' ) %] [% Asset.js("js/autofill.js") | $raw %] [% END %] [% INCLUDE 'datatables.inc' %] diff --git a/koha-tmpl/opac-tmpl/bootstrap/js/autofill.js b/koha-tmpl/opac-tmpl/bootstrap/js/autofill.js index 1263d3dde8..b9385ce9a2 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/js/autofill.js +++ b/koha-tmpl/opac-tmpl/bootstrap/js/autofill.js @@ -63,6 +63,7 @@ //field.$target.val(""); field.$target.trigger('autofill-undo'); } + $("#isbn").val(""); self.$undo.hide(); }); -- 2.30.2