Bug 34843: Fix database comment inconsistency on toc_request
Bug 29093 had a dbrev without comment, but added comment to kohastructure. Test plan: Check (or remove) comment on article_requests.toc_request. Run dbrev. Check if comment was added (if you removed). Run t/db/Koha/Database/Commenter.t Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> (cherry picked from commitf809c272af
) Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> (cherry picked from commitf5b5b1d90d
) Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
This commit is contained in:
parent
bcb4327ea8
commit
b662886e99
2 changed files with 20 additions and 1 deletions
17
installer/data/mysql/atomicupdate/bug_34843.pl
Executable file
17
installer/data/mysql/atomicupdate/bug_34843.pl
Executable file
|
@ -0,0 +1,17 @@
|
|||
use Modern::Perl;
|
||||
|
||||
return {
|
||||
bug_number => 34843,
|
||||
description => "Restore comment on article_requests.toc_request",
|
||||
up => sub {
|
||||
my ($args) = @_;
|
||||
my ( $dbh, $out ) = @$args{qw(dbh out)};
|
||||
$dbh->do(
|
||||
q{
|
||||
ALTER TABLE article_requests MODIFY COLUMN toc_request tinyint(4) NOT NULL DEFAULT 0
|
||||
COMMENT 'borrower requested table of contents'
|
||||
AFTER updated_on
|
||||
}
|
||||
);
|
||||
},
|
||||
};
|
|
@ -8,7 +8,9 @@ return {
|
|||
my ($dbh, $out) = @$args{qw(dbh out)};
|
||||
if( !column_exists('article_requests', 'toc_request') ) {
|
||||
$dbh->do( q|
|
||||
ALTER TABLE article_requests ADD COLUMN toc_request tinyint(4) NOT NULL DEFAULT 0 AFTER updated_on
|
||||
ALTER TABLE article_requests ADD COLUMN toc_request tinyint(4) NOT NULL DEFAULT 0
|
||||
COMMENT 'borrower requested table of contents'
|
||||
AFTER updated_on
|
||||
|);
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue