From e2169cdc1ab51ccda06d0fbfca237e9aef7517f8 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Mon, 11 Mar 2019 13:48:33 +0000 Subject: [PATCH] Bug 14567: (follow-up) Rename pref and move to Opac section --- .../atomicupdate/bug_14567_add_es_catalog_browse_syspref.perl | 4 ++-- installer/data/mysql/sysprefs.sql | 2 +- .../intranet-tmpl/prog/en/modules/admin/preferences/opac.pref | 8 ++++++++ .../prog/en/modules/admin/preferences/searching.pref | 8 -------- koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc | 2 +- koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-browse.tt | 2 +- 6 files changed, 13 insertions(+), 13 deletions(-) diff --git a/installer/data/mysql/atomicupdate/bug_14567_add_es_catalog_browse_syspref.perl b/installer/data/mysql/atomicupdate/bug_14567_add_es_catalog_browse_syspref.perl index 6eba8929ed..e0b36a25d5 100644 --- a/installer/data/mysql/atomicupdate/bug_14567_add_es_catalog_browse_syspref.perl +++ b/installer/data/mysql/atomicupdate/bug_14567_add_es_catalog_browse_syspref.perl @@ -3,8 +3,8 @@ if( CheckVersion( $DBversion ) ) { $dbh->do(q{ INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) VALUES - ('BrowseInterface', '0',NULL, "Elasticsearch only: add a page allowing users to 'browse' all items in the collection",'YesNo') + ('OpacBrowseInterface', '0',NULL, "Elasticsearch only: add a page allowing users to 'browse' all items in the collection",'YesNo') }); SetVersion( $DBversion ); - print "Upgrade to $DBversion done (Bug 14567: Add BrowseInterface syspref)\n"; + print "Upgrade to $DBversion done (Bug 14567: Add OpacBrowseInterface syspref)\n"; } diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql index 09810cea7c..7dc00a71ea 100644 --- a/installer/data/mysql/sysprefs.sql +++ b/installer/data/mysql/sysprefs.sql @@ -99,7 +99,6 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('BorrowersTitles','Mr|Mrs|Miss|Ms',NULL,'Define appropriate Titles for patrons','free'), ('BorrowerUnwantedField','',NULL,'Name the fields you don\'t need to store for a patron\'s account','free'), ('BranchTransferLimitsType','ccode','itemtype|ccode','When using branch transfer limits, choose whether to limit by itemtype or collection code.','Choice'), -('BrowseInterface', '0',NULL, "Elasticsearch only: add a page allowing users to 'browse' all items in the collection",'YesNo'), ('BrowseResultSelection','0',NULL,'Enable/Disable browsing search results fromt the bibliographic record detail page in staff client','YesNo'), ('CalculateFinesOnReturn','1','','Switch to control if overdue fines are calculated on return or not','YesNo'), ('CalendarFirstDayOfWeek','0','0|1|2|3|4|5|6','Select the first day of week to use in the calendar.','Choice'), @@ -342,6 +341,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('OpacAuthorities','1',NULL,'If ON, enables the search authorities link on OPAC','YesNo'), ('OPACBaseURL','',NULL,'Specify the Base URL of the OPAC, e.g., http://opac.mylibrary.com, including the protocol (http:// or https://). Otherwise, the http:// will be added automatically by Koha upon saving.','Free'), ('opacbookbag','1','','If ON, enables display of Cart feature','YesNo'), +('OpacBrowseInterface', '0',NULL, "Elasticsearch only: add a page allowing users to 'browse' all items in the collection",'YesNo'), ('OpacBrowser','0',NULL,'If ON, enables subject authorities browser on OPAC (needs to set misc/cronjob/sbuild_browser_and_cloud.pl)','YesNo'), ('OpacBrowseResults','1',NULL,'Disable/enable browsing and paging search results from the OPAC detail page.','YesNo'), ('OpacCloud','0',NULL,'If ON, enables subject cloud on OPAC','YesNo'), diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref index da1d86540c..9353ff54d0 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref @@ -517,6 +517,14 @@ OPAC: - pref: OPACISBD type: textarea class: code + - + - pref: OpacBrowseInterface + default: 0 + choices: + yes: Enable + no: Disable + - "(Elasticsearch only) Enable the interface allowing to browse all holdings." + Search Form: Policy: - - pref: SearchMyLibraryFirst diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref index 7c4330947c..43ce1f8962 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref @@ -86,14 +86,6 @@ Searching: no: Disable - "browsing search results from the bibliographic record detail page in staff client." - - - pref: BrowseInterface - default: 0 - choices: - yes: Enable - no: Disable - - "(Elasticsearch only) Enable the interface allowing to browse all holdings." - Search Form: - - - Load the unlogged history to the next user. - pref : LoadSearchHistoryToTheFirstLoggedUser default: 0 diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc index f3665eb3aa..378b88f628 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc +++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc @@ -277,7 +277,7 @@ [% IF Koha.Preference( 'TagsEnabled' ) == 1 %]
  • Tag cloud
  • [% END %] [% IF Koha.Preference( 'OpacCloud' ) == 1 %]
  • Subject cloud
  • [% END %] [% IF Koha.Preference( 'OpacTopissue' ) == 1 %]
  • Most popular
  • [% END %] - [% IF Koha.Preference('SearchEngine') == 'Elasticsearch' && Koha.Preference( 'BrowseInterface' ) == 1 %]
  • Browse interface
  • [% END %] + [% IF Koha.Preference('SearchEngine') == 'Elasticsearch' && Koha.Preference( 'OpacBrowseInterface' ) == 1 %]
  • Browse interface
  • [% END %] [% IF Koha.Preference( 'suggestion' ) == 1 %] [% IF Koha.Preference( 'AnonSuggestions' ) == 1 %]
  • Purchase suggestions
  • diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-browse.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-browse.tt index de31120091..28374261b9 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-browse.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-browse.tt @@ -18,7 +18,7 @@
    - [% IF Koha.Preference('SearchEngine') == 'Elasticsearch' && Koha.Preference('BrowseInterface') %] + [% IF Koha.Preference('SearchEngine') == 'Elasticsearch' && Koha.Preference('OpacBrowseInterface') %] [% IF ( OpacNav || OpacNavBottom ) %]
    -- 2.11.0