From bc398d5b97e3c426433f716670f44423a0a87199 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Mon, 25 Jul 2011 11:33:23 +0200 Subject: [PATCH] 6094 Fixing ModAuthority problems MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Only contains db revision to insert new table need_merge_authorities. You can apply the revision by running cgi-bin/koha/installer/install.pl?step=3&op=updatestructure. (Will not change your version while testing.) Oct 19, 2011: Rebased after functionality patch signoff. Signed-off-by: Frédéric Demians Signed-off-by: Chris Cormack Signed-off-by: Chris Nighswonger --- installer/data/mysql/kohastructure.sql | 11 +++++++++++ installer/data/mysql/updatedatabase.pl | 7 +++++++ 2 files changed, 18 insertions(+) diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index 43116bfb63..bfabe124a8 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -1304,6 +1304,17 @@ CREATE TABLE `matchchecks` ( REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8; +-- +-- Table structure for table `need_merge_authorities` +-- + +DROP TABLE IF EXISTS `need_merge_authorities`; +CREATE TABLE `need_merge_authorities` ( + `id` int NOT NULL auto_increment PRIMARY KEY, + `authid` bigint NOT NULL, + `done` tinyint DEFAULT 0 +) ENGINE=InnoDB DEFAULT CHARSET=utf8; + -- -- Table structure for table `notifys` -- diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index fa18bd217e..881c51cc62 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -4431,6 +4431,13 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { SetVersion($DBversion); } +$DBversion = "3.04.00.XXX"; +if (C4::Context->preference("Version") < TransformToNum($DBversion)) { + $dbh->do("CREATE TABLE need_merge_authorities (id int NOT NULL auto_increment PRIMARY KEY, authid bigint NOT NULL, done tinyint DEFAULT 0) ENGINE=InnoDB DEFAULT CHARSET=utf8"); + print "Upgrade to $DBversion done (6094: Fixing ModAuthority problems, add a need_merge_authorities table)\n"; + SetVersion($DBversion); +} + =head1 FUNCTIONS =head2 DropAllForeignKeys($table) -- 2.39.5