Bugzilla – Attachment 150839 Details for
Bug 33567
Remove fallback for Reference_NFL_statuses in C4/XSLT module
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33567: Add a dbrev for installation with empty pref
Bug-33567-Add-a-dbrev-for-installation-with-empty-.patch (text/plain), 1.68 KB, created by
Jonathan Druart
on 2023-05-09 10:23:16 UTC
(
hide
)
Description:
Bug 33567: Add a dbrev for installation with empty pref
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2023-05-09 10:23:16 UTC
Size:
1.68 KB
patch
obsolete
>From 871d2bc9e2c190102880735959b5339dc0721b6f Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Thu, 20 Apr 2023 06:52:50 +0000 >Subject: [PATCH] Bug 33567: Add a dbrev for installation with empty pref > >To keep current behavior, we can copy the removed fallback >into the syspref value in case someone might have cleared the pref. > >Note: We are not restoring deleted prefs here; that is a data problem >outside the scope of this report. A regular installation should always >have this pref. > >Test plan: >Run updatedatabase.pl >Bonus: Clear the pref Reference_NFL_Statuses and run again, verify that >the pref has changed. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > installer/data/mysql/atomicupdate/bug_33567.pl | 17 +++++++++++++++++ > 1 file changed, 17 insertions(+) > create mode 100755 installer/data/mysql/atomicupdate/bug_33567.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_33567.pl b/installer/data/mysql/atomicupdate/bug_33567.pl >new file mode 100755 >index 00000000000..70f424ecbf8 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_33567.pl >@@ -0,0 +1,17 @@ >+use Modern::Perl; >+ >+return { >+ bug_number => 33567, >+ description => "Replace empty Reference_NFL_Statuses pref", >+ up => sub { >+ my ($args) = @_; >+ my ($dbh, $out) = @$args{qw(dbh out)}; >+ >+ my $rv = $dbh->do(q{ >+ UPDATE systempreferences SET value='1|2' >+ WHERE variable = 'Reference_NFL_Statuses' AND COALESCE(value,'')='' >+ }); >+ say $out "Updated preference Reference_NFL_Statuses to default" >+ if $rv && $rv == 1; >+ }, >+}; >-- >2.25.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 33567
:
149921
|
149922
|
149923
|
150837
|
150838
| 150839