From b3a4f1d3851ae880aa3fe21c57b590646211dde6 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 --- installer/data/mysql/atomicupdate/bug_35604.pl | 14 ++++++++++++++ installer/data/mysql/mandatory/sysprefs.sql | 1 + .../admin/preferences/interlibrary_loans.pref | 7 ++++++- 3 files changed, 21 insertions(+), 1 deletion(-) 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 00000000000..bd2f4604ad7 --- /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 8c19ccd1272..fabe47257f8 100644 --- a/installer/data/mysql/mandatory/sysprefs.sql +++ b/installer/data/mysql/mandatory/sysprefs.sql @@ -313,6 +313,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('ILLModule','0','If ON, enables the interlibrary loans module.','','YesNo'), ('ILLModuleCopyrightClearance','','70|10','Enter text to enable the copyright clearance stage of request creation. Text will be displayed','Textarea'), ('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 5031fbdc1cf..c6d998b56fa 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 @@ -81,4 +81,9 @@ Interlibrary loans: - pref: ILLModuleDisclaimerByType type: textarea syntax: text/x-yaml - class: code \ No newline at end of file + 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 \ No newline at end of file -- 2.39.2