From 4b715abdc10345f3e1c92fbcec4b43a312d084ad Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Mon, 26 Mar 2018 15:10:54 +0200 Subject: [PATCH] Bug 20472: Db rev for new preference ArticleRequestsSupportedFormats This preference controls which formats are actually offered to patrons of the library via the Article Request feature. By default, it only contains PHOTOCOPY. This is default behavior. The request format SCAN will be made possible by this report and can be added by changing the preference. Test plan: Run the dbrev. Check the new pref on Administration. Signed-off-by: Marcel de Rooy Signed-off-by: Martin Renvoize Signed-off-by: Nick Clemens Signed-off-by: Jonathan Druart --- installer/data/mysql/atomicupdate/bug_20472b.perl | 8 ++++++++ installer/data/mysql/mandatory/sysprefs.sql | 1 + .../prog/en/modules/admin/preferences/circulation.pref | 5 +++++ 3 files changed, 14 insertions(+) create mode 100644 installer/data/mysql/atomicupdate/bug_20472b.perl diff --git a/installer/data/mysql/atomicupdate/bug_20472b.perl b/installer/data/mysql/atomicupdate/bug_20472b.perl new file mode 100644 index 0000000000..d33859c525 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_20472b.perl @@ -0,0 +1,8 @@ +$DBversion = 'XXX'; # will be replaced by the RM +if( CheckVersion( $DBversion ) ) { + $dbh->do(q{ + INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES + ('ArticleRequestsSupportedFormats', 'PHOTOCOPY', 'PHOTOCOPY|SCAN', 'List supported formats between vertical bars', 'free') + }); + NewVersion( $DBversion, 20472, "Add syspref ArticleRequestsSupportedFormats"); +} diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql index d7a01a7bcc..6b66e42c14 100644 --- a/installer/data/mysql/mandatory/sysprefs.sql +++ b/installer/data/mysql/mandatory/sysprefs.sql @@ -61,6 +61,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('ArticleRequestsMandatoryFields', '', NULL, 'Comma delimited list of required fields for bibs where article requests rule = ''yes''', 'multiple'), ('ArticleRequestsMandatoryFieldsItemOnly', '', NULL, 'Comma delimited list of required fields for bibs where article requests rule = ''item_only''', 'multiple'), ('ArticleRequestsMandatoryFieldsRecordOnly', '', NULL, 'Comma delimited list of required fields for bibs where article requests rule = ''bib_only''', 'multiple'), +('ArticleRequestsSupportedFormats', 'PHOTOCOPY', 'PHOTOCOPY|SCAN', 'List supported formats between vertical bars', 'free'), ('AudioAlerts','0','','Enable circulation sounds during checkin and checkout in the staff interface. Not supported by all web browsers yet.','YesNo'), ('AuthDisplayHierarchy','0','','Display authority hierarchies','YesNo'), ('AuthFailureLog','0',NULL,'If enabled, log authentication failures','YesNo'), diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref index aa3856dfcc..3ae763c4ea 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref @@ -1240,6 +1240,11 @@ Circulation: pages: Pages chapters: Chapters - + - + - "The following article request formats are supported:" + - pref: ArticleRequestsSupportedFormats + - "(Valid choices are currently: PHOTOCOPY and SCAN. Separate the supported formats by a vertical bar. The first listed format is selected by default when you request via the OPAC.)" + Return claims: - - When marking a checkout as "claims returned", -- 2.39.2