Bug 24436: Add 'Reserve' options to branchtransfers trigger
Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
This commit is contained in:
parent
3ebe29bf2a
commit
46da9fcecc
|
|
@ -72,7 +72,7 @@ __PACKAGE__->table("branchtransfers");
|
|||
=head2 reason
|
||||
|
||||
data_type: 'enum'
|
||||
extra: {list => ["Manual","StockrotationAdvance","StockrotationRepatriation","ReturnToHome","ReturnToHolding","RotatingCollection"]}
|
||||
extra: {list => ["Manual","StockrotationAdvance","StockrotationRepatriation","ReturnToHome","ReturnToHolding","RotatingCollection","Reserve","LostReserve","CancelReserve"]}
|
||||
is_nullable: 1
|
||||
|
||||
=cut
|
||||
|
|
@ -128,6 +128,9 @@ __PACKAGE__->add_columns(
|
|||
"ReturnToHome",
|
||||
"ReturnToHolding",
|
||||
"RotatingCollection",
|
||||
"Reserve",
|
||||
"LostReserve",
|
||||
"CancelReserve",
|
||||
],
|
||||
},
|
||||
is_nullable => 1,
|
||||
|
|
@ -194,8 +197,8 @@ __PACKAGE__->belongs_to(
|
|||
);
|
||||
|
||||
|
||||
# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-20 10:50:34
|
||||
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Z5PcwyW+X3XM1CeO6CZKBw
|
||||
# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-20 11:24:33
|
||||
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:50FpCj6vWH5O8MThCy/1hA
|
||||
|
||||
sub koha_object_class {
|
||||
'Koha::Item::Transfer';
|
||||
|
|
|
|||
|
|
@ -0,0 +1,27 @@
|
|||
$DBversion = 'XXX'; # will be replaced by the RM
|
||||
if( CheckVersion( $DBversion ) ) {
|
||||
|
||||
# Add reserve reasons enum
|
||||
$dbh->do(
|
||||
qq{
|
||||
ALTER TABLE
|
||||
`branchtransfers`
|
||||
MODIFY COLUMN
|
||||
`reason` enum(
|
||||
'Manual',
|
||||
'StockrotationAdvance',
|
||||
'StockrotationRepatriation',
|
||||
'ReturnToHome',
|
||||
'ReturnToHolding',
|
||||
'RotatingCollection',
|
||||
'Reserve',
|
||||
'LostReserve',
|
||||
'CancelReserve'
|
||||
)
|
||||
AFTER `comments`
|
||||
}
|
||||
);
|
||||
|
||||
SetVersion( $DBversion );
|
||||
print "Upgrade to $DBversion done (Bug 24299 - Add 'reserve' reasons to branchtransfers enum)\n";
|
||||
}
|
||||
|
|
@ -906,7 +906,7 @@ CREATE TABLE `branchtransfers` ( -- information for items that are in transit be
|
|||
`datearrived` datetime default NULL, -- the date the transfer arrived at its destination
|
||||
`tobranch` varchar(10) NOT NULL default '', -- the branch the transfer was going to
|
||||
`comments` LONGTEXT, -- any comments related to the transfer
|
||||
`reason` ENUM('Manual', 'StockrotationAdvance', 'StockrotationRepatriation', 'ReturnToHome', 'ReturnToHolding', 'RotatingCollection'), -- what triggered the transfer
|
||||
`reason` ENUM('Manual', 'StockrotationAdvance', 'StockrotationRepatriation', 'ReturnToHome', 'ReturnToHolding', 'RotatingCollection', 'Reserve', 'LostReserve', 'CancelReserve'), -- what triggered the transfer
|
||||
PRIMARY KEY (`branchtransfer_id`),
|
||||
KEY `frombranch` (`frombranch`),
|
||||
KEY `tobranch` (`tobranch`),
|
||||
|
|
|
|||
Loading…
Reference in New Issue