View | Details | Raw Unified | Return to bug 29093
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/bug_29093.pl (+15 lines)
Line 0 Link Here
1
use Modern::Perl;
2
3
return {
4
    bug_number => "29093",
5
    description => "Add column article_requests.toc_request",
6
    up => sub {
7
        my ($args) = @_;
8
        my ($dbh, $out) = @$args{qw(dbh out)};
9
        if( !column_exists('article_requests', 'toc_request') ) {
10
            $dbh->do( q|
11
                ALTER TABLE article_requests ADD COLUMN toc_request tinyint(4) NOT NULL DEFAULT 0 AFTER updated_on
12
            |);
13
        }
14
    },
15
}
(-)a/installer/data/mysql/kohastructure.sql (-1 / +1 lines)
Lines 756-761 CREATE TABLE `article_requests` ( Link Here
756
  `cancellation_reason` varchar(80) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'optional authorised value AR_CANCELLATION',
756
  `cancellation_reason` varchar(80) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'optional authorised value AR_CANCELLATION',
757
  `created_on` timestamp NULL DEFAULT NULL COMMENT 'Be careful with two timestamps in one table not allowing NULL',
757
  `created_on` timestamp NULL DEFAULT NULL COMMENT 'Be careful with two timestamps in one table not allowing NULL',
758
  `updated_on` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
758
  `updated_on` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
759
  `toc_request` tinyint(4) NOT NULL DEFAULT 0 COMMENT 'borrower requested table of contents',
759
  PRIMARY KEY (`id`),
760
  PRIMARY KEY (`id`),
760
  KEY `borrowernumber` (`borrowernumber`),
761
  KEY `borrowernumber` (`borrowernumber`),
761
  KEY `biblionumber` (`biblionumber`),
762
  KEY `biblionumber` (`biblionumber`),
762
- 

Return to bug 29093