Bug 15685: Fix DB columns order
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 10 Oct 2017 20:01:25 +0000 (17:01 -0300)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 11 Oct 2017 16:08:47 +0000 (13:08 -0300)
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
installer/data/mysql/atomicupdate/bug15685.perl
installer/data/mysql/kohastructure.sql

index 7721df5..620696b 100644 (file)
@@ -4,7 +4,7 @@ if( CheckVersion( $DBversion ) ) {
     unless( column_exists('aqbasket','create_items') ){
         $dbh->do(q{
             ALTER TABLE aqbasket
-                ADD COLUMN create_items ENUM('ordering', 'receiving', 'cataloguing') default NULL
+                ADD COLUMN create_items ENUM('ordering', 'receiving', 'cataloguing') default NULL AFTER is_standing
         });
     }
 
index 9b00860..3cdee18 100644 (file)
@@ -2992,9 +2992,9 @@ CREATE TABLE `aqbasket` ( -- stores data about baskets in acquisitions
   `basketgroupid` int(11), -- links this basket to its group (aqbasketgroups.id)
   `deliveryplace` varchar(10) default NULL, -- basket delivery place
   `billingplace` varchar(10) default NULL, -- basket billing place
-  create_items ENUM('ordering', 'receiving', 'cataloguing') default NULL, -- when items should be created for orders in this basket
   branch varchar(10) default NULL, -- basket branch
   is_standing TINYINT(1) NOT NULL DEFAULT 0, -- orders in this basket are standing
+  create_items ENUM('ordering', 'receiving', 'cataloguing') default NULL, -- when items should be created for orders in this basket
   PRIMARY KEY  (`basketno`),
   KEY `booksellerid` (`booksellerid`),
   KEY `basketgroupid` (`basketgroupid`),