From 1a1cc16b9dbb9df298b991154c3bec9f527a5ed2 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 18 Jan 2022 11:35:17 +0100 Subject: [PATCH] Bug 29897: Add new pref OPACAuthorIdentifiers Sponsored-by: Orex Digital --- installer/data/mysql/atomicupdate/bug_29897.pl | 14 ++++++++++++++ installer/data/mysql/mandatory/sysprefs.sql | 1 + .../prog/en/modules/admin/preferences/opac.pref | 7 +++++++ 3 files changed, 22 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug_29897.pl diff --git a/installer/data/mysql/atomicupdate/bug_29897.pl b/installer/data/mysql/atomicupdate/bug_29897.pl new file mode 100755 index 00000000000..719d8e9c9b8 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_29897.pl @@ -0,0 +1,14 @@ +use Modern::Perl; + +return { + bug_number => "29897", + description => "Add new system preference OPACAuthorIdentifiers", + up => sub { + my ($args) = @_; + my ($dbh, $out) = @$args{qw(dbh out)}; + $dbh->do(q{ + INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES + ('OPACAuthorIdentifiers','0','','Display author identifiers on the OPAC detail page','YesNo') + }); + }, +}; diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql index 9cdd4f64ee4..4dc4a85a770 100644 --- a/installer/data/mysql/mandatory/sysprefs.sql +++ b/installer/data/mysql/mandatory/sysprefs.sql @@ -394,6 +394,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('OpacAllowSharingPrivateLists','0',NULL,'If set, allows opac users to share private lists with other patrons','YesNo'), ('OPACAllowUserToChooseBranch','1','1','Allow the user to choose the branch they want to pickup their hold from','YesNo'), ('OPACAmazonCoverImages','0','','Display cover images on OPAC from Amazon Web Services','YesNo'), +('OPACAuthorIdentifiers','0','','Display author identifiers on the OPAC detail page','YesNo'), ('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'), 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 a73702c9bbd..9e44237b4dd 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 @@ -537,6 +537,13 @@ OPAC: 1: Enable 0: Disable - "interface for browsing all holdings (Elasticsearch only)." + - + - pref: OPACAuthorIdentifiers + default: 0 + choices: + 1: Display + 0: "Don't display" + - "author identifiers for research publications." OpenURL: - - 'Complete URL of OpenURL resolver (starting with http:// or https://):' -- 2.25.1