From 5e54a0ccb3dad51f911aa7e2e929154775f17e51 Mon Sep 17 00:00:00 2001 From: Pedro Amorim Date: Tue, 19 Dec 2023 10:26:09 +0000 Subject: [PATCH] Bug 35604: New AutoILLBackendPriority sys prefs Signed-off-by: David Nind --- installer/data/mysql/atomicupdate/bug_35604.pl | 14 ++++++++++++++ installer/data/mysql/mandatory/sysprefs.sql | 1 + .../admin/preferences/interlibrary_loans.pref | 5 +++++ 3 files changed, 20 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug_35604.pl diff --git a/installer/data/mysql/atomicupdate/bug_35604.pl b/installer/data/mysql/atomicupdate/bug_35604.pl new file mode 100755 index 0000000000..bd2f4604ad --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_35604.pl @@ -0,0 +1,14 @@ +use Modern::Perl; +return { + bug_number => "35604", + description => "Add new AutoILLBackendPriority system preferences", + up => sub { + my ($args) = @_; + my ( $dbh, $out ) = @$args{qw(dbh out)}; + + $dbh->do( + q{ INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) VALUES ('AutoILLBackendPriority','',NULL,'Set the automatic backend selection priority','ILLBackends'); } + ); + say $out "Added new system preference 'AutoILLBackendPriority'"; + }, +}; diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql index 06ebba4511..9b7193c633 100644 --- a/installer/data/mysql/mandatory/sysprefs.sql +++ b/installer/data/mysql/mandatory/sysprefs.sql @@ -319,6 +319,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('IllLog', 0, '', 'If ON, log information about ILL requests', 'YesNo'), ('ILLModule','0','If ON, enables the interlibrary loans module.','','YesNo'), ('ILLModuleDisclaimerByType','','','YAML defining disclaimer settings for each ILL request type','Textarea'), +('AutoILLBackendPriority','',NULL,'Set the automatic backend selection priority','ILLBackends'), ('ILLModuleUnmediated','0','','If enabled, try to immediately progress newly placed ILL requests.','YesNo'), ('ILLOpacbackends',NULL,NULL,'ILL backends to enabled for OPAC initiated requests','multiple'), ('ILLPartnerCode','IL','','Patrons from this patron category will be used as partners to place ILL requests with','free'), diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/interlibrary_loans.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/interlibrary_loans.pref index c7494555d4..f99234b8b3 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/interlibrary_loans.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/interlibrary_loans.pref @@ -77,3 +77,8 @@ Interlibrary loans: type: textarea syntax: text/x-yaml class: code + - + - "Select which backends will be queried for availability and in what order of priority. The first available backend will be suggested to place the request with.
" + - "If no backend is selected, automatic backend selection will not take place." + - pref: AutoILLBackendPriority + type: ill-backends -- 2.39.2