From e5613897db1caaf3ecac3261ab8c7ea64c610d37 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Fri, 6 Sep 2024 09:58:18 +0000 Subject: [PATCH] Bug 23685: (follow-up) Dbrev for new preferences Content-Type: text/plain; charset=utf-8 Test plan: Run updatedatabase. Signed-off-by: Marcel de Rooy --- installer/data/mysql/atomicupdate/bug23685.pl | 21 +++++++++++++++++++ installer/data/mysql/mandatory/sysprefs.sql | 2 ++ 2 files changed, 23 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug23685.pl diff --git a/installer/data/mysql/atomicupdate/bug23685.pl b/installer/data/mysql/atomicupdate/bug23685.pl new file mode 100755 index 0000000000..0fc8ce891e --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug23685.pl @@ -0,0 +1,21 @@ +use Modern::Perl; +use Koha::Installer::Output qw(say_warning say_failure say_success say_info); + +return { + bug_number => "23685", + description => "Add prefs GuidedReportsExportLimit and ReportingAllowsODS_Export", + up => sub { + my ($args) = @_; + my ( $dbh, $out ) = @$args{qw(dbh out)}; + + # sysprefs + $dbh->do( + q{ + INSERT IGNORE INTO systempreferences ( variable, value, options, explanation, type ) VALUES + ('GuidedReportsExportLimit',NULL,NULL,'Limit for reporting downloads (if not empty)','Integer'), + ('ReportingAllowsODS_Export',1,NULL,'Shows or hides ODS download in Reporing','YesNo'); + } + ); + say $out "Added new system preferences: GuidedReportsExportLimit and ReportingAllowsODS_Export"; + }, +}; diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql index a865f86cb2..d198018045 100644 --- a/installer/data/mysql/mandatory/sysprefs.sql +++ b/installer/data/mysql/mandatory/sysprefs.sql @@ -292,6 +292,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('GoogleOpenIDConnectDefaultBranch', '','','This branch code will be used to create Google OpenID Connect patrons.','Textarea'), ('GoogleOpenIDConnectDefaultCategory','','','This category code will be used to create Google OpenID Connect patrons.','Textarea'), ('GoogleOpenIDConnectDomain', '', NULL, 'Restrict Google OpenID Connect to this domain (or subdomains of this domain). Leave blank for all Google domains', 'Free'), +('GuidedReportsExportLimit',NULL,NULL,'Limit for reporting downloads (if not empty)','Integer'), ('hide_marc','0',NULL,'If ON, disables display of MARC fields, subfield codes & indicators (still shows data)','YesNo'), ('hidelostitems','0','','If ON, disables display of\"lost\" items in OPAC.','YesNo'), ('HidePatronName','0','','If this is switched on, patron\'s cardnumber will be shown instead of their name on the holds and catalog screens','YesNo'), @@ -655,6 +656,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('RenewalSendNotice','0','',NULL,'YesNo'), ('RenewSerialAddsSuggestion','0',NULL,'If ON, adds a new suggestion at serial subscription renewal','YesNo'), ('RentalFeesCheckoutConfirmation', '0', NULL , 'Allow user to confirm when checking out an item with rental fees.', 'YesNo'), +('ReportingAllowsODS_Export',1,NULL,'Shows or hides ODS download in Reporing','YesNo'), ('ReplytoDefault','',NULL,'Use this email address as the replyto in emails','Free'), ('ReportsLog','0',NULL,'If ON, log information about reports.','YesNo'), ('RequireCashRegister','0',NULL,'Require a cash register when collecting a payment','YesNo'), -- 2.30.2