From 9c79eed689b67686f92847a84cb61742bae4babe Mon Sep 17 00:00:00 2001 From: David Cook Date: Thu, 20 Mar 2025 02:05:26 +0000 Subject: [PATCH] Bug 39374: Database changes Signed-off-by: Brendan Gallagher --- .../data/mysql/atomicupdate/bug_39374.pl | 21 +++++++++++++++++++ installer/data/mysql/mandatory/sysprefs.sql | 1 + 2 files changed, 22 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug_39374.pl diff --git a/installer/data/mysql/atomicupdate/bug_39374.pl b/installer/data/mysql/atomicupdate/bug_39374.pl new file mode 100755 index 0000000000..61b430cdbb --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_39374.pl @@ -0,0 +1,21 @@ +use Modern::Perl; +use Koha::Installer::Output qw(say_warning say_success say_info); + +return { + bug_number => "39374", + description => "Add system preference OPACDisableSendList", + up => sub { + my ($args) = @_; + my ( $dbh, $out ) = @$args{qw(dbh out)}; + + # Do you stuffs here + $dbh->do( + q{ + INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) + VALUES ('OPACDisableSendList','0',NULL,'Allow OPAC users to email lists via a "Send list" button','YesNo'); + } + ); + + say_success( $out, "Added new system preference 'OPACDisableSendList'" ); + }, +}; diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql index 2bf9d0b648..6f5241afb4 100644 --- a/installer/data/mysql/mandatory/sysprefs.sql +++ b/installer/data/mysql/mandatory/sysprefs.sql @@ -488,6 +488,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('OPACdefaultSortOrder','dsc','asc|dsc|za|az','Specify the default sort order','Choice'), ('OPACDetailQRCode','0','','Enable the display of a QR Code on the OPAC detail page','YesNo'), ('OPACdidyoumean','',NULL,'Did you mean? configuration for the OPAC. Do not change, as this is controlled by /cgi-bin/koha/admin/didyoumean.pl.','Free'), +('OPACDisableSendList','0',NULL,'Allow OPAC users to email lists via a "Send list" button','YesNo'), ('OPACDisplay856uAsImage','OFF','OFF|Details|Results|Both','Display the URI in the 856u field as an image, the corresponding OPACXSLT option must be on','Choice'), ('OpacExportOptions','bibtex,dc,marcxml,marc8,utf8,marcstd,mods,ris,isbd','','Define export options available on OPAC detail page.','multiple'), ('OPACFallback', 'prog', 'bootstrap|prog', 'Define the fallback theme for the OPAC interface.', 'Themes'), -- 2.39.5