From d7da6d1fea141a6b5c026b36780c6d840b52a25c Mon Sep 17 00:00:00 2001 From: Charlotte Cordwell Date: Thu, 18 Jan 2018 01:29:05 +0000 Subject: [PATCH] Bug 19892: Replace numbersphr variable with Koha.Preference('OPACNumbersPreferPhrase') in OPAC Test Case 1) Check that the following files have been changed properly. opac/opac-search.pl opac/opac-main.pl koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-advsearch.tt 2)Apply bug 3) Check that there are no differences in behaviour as a result of the patch. Signed-off-by: Roch D'Amour Signed-off-by: Katrin Fischer Signed-off-by: Katrin Fischer Signed-off-by: Jonathan Druart --- koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-advsearch.tt | 4 ++-- opac/opac-main.pl | 4 ---- opac/opac-search.pl | 3 --- 3 files changed, 2 insertions(+), 9 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-advsearch.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-advsearch.tt index 3037c7263b..421f91efbd 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-advsearch.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-advsearch.tt @@ -54,7 +54,7 @@ [% IF ( expanded_options ) %] - [% IF ( numbersphr) %] + [% IF ( Koha.Preference('OPACNumbersPreferPhrase') ) %] [% ELSE %] @@ -79,7 +79,7 @@ [% IF ( expanded_options ) %] - [% IF ( numbersphr) %] + [% IF ( Koha.Preference('OPACNumbersPreferPhrase') ) %] [% ELSE %] diff --git a/opac/opac-main.pl b/opac/opac-main.pl index b007b81ab5..a397627059 100755 --- a/opac/opac-main.pl +++ b/opac/opac-main.pl @@ -100,8 +100,4 @@ if (C4::Context->preference('GoogleIndicTransliteration')) { $template->param('GoogleIndicTransliteration' => 1); } -if (C4::Context->preference('OPACNumbersPreferPhrase')) { - $template->param('numbersphr' => 1); -} - output_html_with_http_headers $input, $cookie, $template->output; diff --git a/opac/opac-search.pl b/opac/opac-search.pl index 808cbdf25b..d7dccd3867 100755 --- a/opac/opac-search.pl +++ b/opac/opac-search.pl @@ -380,9 +380,6 @@ if ( $template_type && $template_type eq 'advsearch' ) { } } - if (C4::Context->preference('OPACNumbersPreferPhrase')) { - $template->param('numbersphr' => 1); - } output_html_with_http_headers $cgi, $cookie, $template->output; exit; -- 2.39.5