From d1d1d3bea1edf6d172c330dcb4e531b2349c7eb3 Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Wed, 27 Dec 2017 12:24:36 -0300 Subject: [PATCH] Bug 15492: New sysprefs and permissions In order to make this module unrelated to the SCO module, this patch introduces the following sysprefs: - SelfCheckInMainUserBlock - SelfCheckInModuleUserID - SelfCheckInTimeout - SelfCheckInUserCSS - SelfCheckInUserJS It also adds a new user flag and sub-permission: - self_check => self_checkin_module and moves the circulate => self_checkout permission into - self_check => self_checkout_module Descriptions are adjusted accordingly. Signed-off-by: Tomas Cohen Arazi --- installer/data/mysql/atomicupdate/bug_15492.perl | 62 +++++++++++++++++++++- installer/data/mysql/sysprefs.sql | 4 ++ installer/data/mysql/userflags.sql | 3 +- installer/data/mysql/userpermissions.sql | 5 +- .../intranet-tmpl/prog/en/includes/permissions.inc | 9 ++-- .../en/modules/admin/preferences/circulation.pref | 20 +++++++ 6 files changed, 95 insertions(+), 8 deletions(-) diff --git a/installer/data/mysql/atomicupdate/bug_15492.perl b/installer/data/mysql/atomicupdate/bug_15492.perl index f4678074fc..54d37bcd8c 100644 --- a/installer/data/mysql/atomicupdate/bug_15492.perl +++ b/installer/data/mysql/atomicupdate/bug_15492.perl @@ -1,10 +1,68 @@ $DBversion = 'XXX'; if( CheckVersion( $DBversion ) ) { - $dbh->do(q| + $dbh->do(q{ + INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) + VALUES ('SelfCheckInMainUserBlock', '', '70|10', 'Add a block of HTML that will display on the self check-in screen.', 'Textarea'); + }); + + $dbh->do(q{ INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) VALUES ('SelfCheckInModule', 0, NULL, 'Enable the standalone self-checkin module.', 'YesNo'); - |); + }); + + $dbh->do(q{ + INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) + VALUES ('SelfCheckInModuleUserID', NULL, NULL, 'Patron ID (borrowernumber) to be allowed on the self-checkin module.', 'Integer'); + }); + + $dbh->do(q{ + INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) + VALUES ('SelfCheckInTimeout', 120, NULL, 'Define the number of seconds before the self check-in module times out.', 'Integer'); + }); + + $dbh->do(q{ + INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) + VALUES ('SelfCheckInUserCSS', '', NULL, 'Add CSS to be included in the self check-in module in an embedded