From c11a57652620e29ea1ee9ddc7b2c72020cdb96db Mon Sep 17 00:00:00 2001 From: Matthias Meusburger Date: Thu, 10 Sep 2009 15:18:01 +0200 Subject: [PATCH] MT 1587 (Follow-up) : CSV export for cart and shelves (export_format table creation) Signed-off-by: Henri-Damien LAURENT --- installer/data/mysql/kohastructure.sql | 14 ++++++++++++++ installer/data/mysql/updatedatabase.pl | 11 ++++++++++- 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index 821bb18d23..be888ddd95 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -742,6 +742,20 @@ CREATE TABLE `ethnicity` ( PRIMARY KEY (`code`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; +-- +-- Table structure for table `export_format` +-- + +DROP TABLE IF EXISTS `export_format`; +CREATE TABLE `export_format` ( + `export_format_id` int(11) NOT NULL auto_increment, + `profile` varchar(255) NOT NULL, + `description` mediumtext NOT NULL, + `marcfields` mediumtext NOT NULL, + PRIMARY KEY (`export_format_id`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Used for CSV export'; + + -- -- Table structure for table `hold_fill_targets` -- diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 7dba9d5fc5..fedfa7033f 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -2692,7 +2692,16 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $DBversion = "3.01.00.062"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("INSERT INTO permissions (module_bit, code, description) VALUES ( 13, 'manage_csv_profiles', 'Manage CSV export profiles')"); - print "Upgrade to $DBversion done (added permissions for csv export profiles)\n"; + $dbh->do(q/ + CREATE TABLE `export_format` ( + `export_format_id` int(11) NOT NULL auto_increment, + `profile` varchar(255) NOT NULL, + `description` mediumtext NOT NULL, + `marcfields` mediumtext NOT NULL, + PRIMARY KEY (`export_format_id`) + ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Used for CSV export'; + /); + print "Upgrade to $DBversion done (added csv export profiles)\n"; } =item -- 2.39.5