Bugzilla – Attachment 142015 Details for
Bug 14783
Allow patrons to change pickup location for non-waiting holds
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14783: Update atomicupdate syntax
Bug-14783-Update-atomicupdate-syntax.patch (text/plain), 3.13 KB, created by
Tomás Cohen Arazi (tcohen)
on 2022-10-17 19:01:27 UTC
(
hide
)
Description:
Bug 14783: Update atomicupdate syntax
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2022-10-17 19:01:27 UTC
Size:
3.13 KB
patch
obsolete
>From 3da8a25253248802e65e6d69af4b2bce4d2d9dee Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@theke.io> >Date: Mon, 17 Oct 2022 15:59:07 -0300 >Subject: [PATCH] Bug 14783: Update atomicupdate syntax > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> >--- > ...OpacAllowPickupLocationChange_syspref.perl | 10 ------- > .../data/mysql/atomicupdate/bug_14783.pl | 30 +++++++++++++++++++ > 2 files changed, 30 insertions(+), 10 deletions(-) > delete mode 100644 installer/data/mysql/atomicupdate/bug_14783-add_OpacAllowPickupLocationChange_syspref.perl > create mode 100755 installer/data/mysql/atomicupdate/bug_14783.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_14783-add_OpacAllowPickupLocationChange_syspref.perl b/installer/data/mysql/atomicupdate/bug_14783-add_OpacAllowPickupLocationChange_syspref.perl >deleted file mode 100644 >index 75d91c65332..00000000000 >--- a/installer/data/mysql/atomicupdate/bug_14783-add_OpacAllowPickupLocationChange_syspref.perl >+++ /dev/null >@@ -1,10 +0,0 @@ >- >- >-$DBversion = 'XXX'; # will be replaced by the RM >-if( CheckVersion( $DBversion ) ) { >- $dbh->do( "INSERT IGNORE INTO systempreferences (variable, value, options, explanation, type) VALUES ('OPACAllowUserToChangeBranch','','Pending, In-Transit, Suspended','Allow users to change the library to pick up a hold for these statuses:','multiple');" ); >- $dbh->do( "UPDATE systempreferences set value = (SELECT CASE WHEN value = 1 THEN 'intransit' ELSE '' END FROM systempreferences WHERE variable = 'OPACInTransitHoldPickupLocationChange')"); >- $dbh->do( "DELETE FROM systempreferences WHERE variable = 'OPACInTransitHoldPickupLocationChange' "); >- # Always end with this (adjust the bug info) >- NewVersion( $DBversion, 14783, "Allow patrons to change pickup location for non-waiting holds"); >-} >diff --git a/installer/data/mysql/atomicupdate/bug_14783.pl b/installer/data/mysql/atomicupdate/bug_14783.pl >new file mode 100755 >index 00000000000..fe5f7c04c4f >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_14783.pl >@@ -0,0 +1,30 @@ >+use Modern::Perl; >+ >+return { >+ bug_number => "14783", >+ description => "Allow patrons to change pickup location for non-waiting holds", >+ up => sub { >+ my ($args) = @_; >+ my ($dbh, $out) = @$args{qw(dbh out)}; >+ >+ $dbh->do(q{ >+ INSERT IGNORE INTO systempreferences (variable, value, options, explanation, type) >+ VALUES ('OPACAllowUserToChangeBranch','','Pending, In-Transit, Suspended','Allow users to change the library to pick up a hold for these statuses:','multiple'); >+ }); >+ >+ $dbh->do(q{ >+ UPDATE systempreferences SET value = (SELECT CASE WHEN value = 1 THEN 'intransit' ELSE '' END >+ FROM systempreferences >+ WHERE variable = 'OPACInTransitHoldPickupLocationChange') >+ }); >+ >+ say $out "Added new system preference 'OPACAllowUserToChangeBranch'"; >+ >+ $dbh->do(q{ >+ DELETE FROM systempreferences >+ WHERE variable = 'OPACInTransitHoldPickupLocationChange' >+ }); >+ >+ say $out "Removed system preference 'OPACInTransitHoldPickupLocationChange'"; >+ }, >+}; >-- >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 14783
:
118189
|
118241
|
123199
|
123271
|
123708
|
123709
|
127488
|
127490
|
127492
|
130344
|
130345
|
130346
|
130347
|
141499
|
141500
|
141501
|
141502
|
141727
|
141728
|
141729
|
141730
|
142009
|
142010
|
142011
|
142012
|
142013
|
142014
| 142015 |
143025