From afa39a7498b3077f904e74bf2cd35fc003310917 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Mon, 2 Mar 2020 16:49:16 +0000 Subject: [PATCH] Bug 16787: Add noReservesAllowed to club holds --- .../bug_16787_add_noReservesAllowed_to_club_holds.perl | 16 ++++++++++++++++ installer/data/mysql/kohastructure.sql | 3 ++- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 installer/data/mysql/atomicupdate/bug_16787_add_noReservesAllowed_to_club_holds.perl diff --git a/installer/data/mysql/atomicupdate/bug_16787_add_noReservesAllowed_to_club_holds.perl b/installer/data/mysql/atomicupdate/bug_16787_add_noReservesAllowed_to_club_holds.perl new file mode 100644 index 0000000000..7cd3fc669a --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_16787_add_noReservesAllowed_to_club_holds.perl @@ -0,0 +1,16 @@ +$DBversion = 'XXX'; +if( CheckVersion( $DBversion ) ) { + $dbh->do(q{ + ALTER TABLE club_holds_to_patron_holds + MODIFY COLUMN error_code + ENUM ( 'damaged', 'ageRestricted', 'itemAlreadyOnHold', + 'tooManyHoldsForThisRecord', 'tooManyReservesToday', + 'tooManyReserves', 'notReservable', 'cannotReserveFromOtherBranches', + 'libraryNotFound', 'libraryNotPickupLocation', 'cannotBeTransferred', + 'noReservesAllowed' + ) + }); + + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 16787: Add noReservesAllowed to club holds error codes)\n"; +} diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index ef3bff04b0..e458575a7b 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -4236,7 +4236,8 @@ CREATE TABLE IF NOT EXISTS club_holds_to_patron_holds ( error_code ENUM ( 'damaged', 'ageRestricted', 'itemAlreadyOnHold', 'tooManyHoldsForThisRecord', 'tooManyReservesToday', 'tooManyReserves', 'notReservable', 'cannotReserveFromOtherBranches', - 'libraryNotFound', 'libraryNotPickupLocation', 'cannotBeTransferred' + 'libraryNotFound', 'libraryNotPickupLocation', 'cannotBeTransferred', + 'noReservesAllowed' ) NULL DEFAULT NULL, error_message varchar(100) NULL DEFAULT NULL, PRIMARY KEY (id), -- 2.11.0