Bugzilla – Attachment 187994 Details for
Bug 28308
Select 'Days in advance' = 0 for Advance notice effectively disables PREDUE notices
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28308: DBrev
Bug-28308-DBrev.patch (text/plain), 1.49 KB, created by
Jonathan Druart
on 2025-10-16 10:56:01 UTC
(
hide
)
Description:
Bug 28308: DBrev
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2025-10-16 10:56:01 UTC
Size:
1.49 KB
patch
obsolete
>From bf522cf4cd191805ce454187323475f4d74849c2 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 16 Oct 2025 12:46:21 +0200 >Subject: [PATCH] Bug 28308: DBrev > >To remove the unnecessary entries from the DB >--- > .../data/mysql/atomicupdate/bug_28308.pl | 23 +++++++++++++++++++ > 1 file changed, 23 insertions(+) > create mode 100755 installer/data/mysql/atomicupdate/bug_28308.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_28308.pl b/installer/data/mysql/atomicupdate/bug_28308.pl >new file mode 100755 >index 00000000000..37b1f83e1df >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_28308.pl >@@ -0,0 +1,23 @@ >+use Modern::Perl; >+use Koha::Installer::Output qw(say_warning say_success say_info); >+ >+return { >+ bug_number => "28308", >+ description => "Remove unnecessary message preference entries", >+ up => sub { >+ my ($args) = @_; >+ my ( $dbh, $out ) = @$args{qw(dbh out)}; >+ >+ # Remove message transport types entries for Advance notice (id=2) if "Days in advance" is 0 or NULL >+ $dbh->do( >+ q{ >+ DELETE bmtp >+ FROM borrower_message_transport_preferences bmtp >+ JOIN borrower_message_preferences bmp >+ ON bmtp.borrower_message_preference_id = bmp.borrower_message_preference_id >+ WHERE bmp.message_attribute_id = 2 >+ AND (bmp.days_in_advance = 0 OR bmp.days_in_advance IS NULL); >+ } >+ ); >+ }, >+}; >-- >2.34.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 28308
:
187992
|
187993
| 187994