From 42d5a49de71a38729349eab82fd66d67c9d38649 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Tue, 16 Jan 2018 16:14:49 +0000 Subject: [PATCH] Bug 13560 - Database changes --- installer/data/mysql/atomicupdate/bug13560.perl | 6 ++++++ installer/data/mysql/kohastructure.sql | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 installer/data/mysql/atomicupdate/bug13560.perl diff --git a/installer/data/mysql/atomicupdate/bug13560.perl b/installer/data/mysql/atomicupdate/bug13560.perl new file mode 100644 index 0000000..81e39bc --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug13560.perl @@ -0,0 +1,6 @@ +$DBversion = 'XXX'; # will be replaced by the RM +if( CheckVersion( $DBversion ) ) { + $dbh->do( "ALTER TABLE marc_modification_template_actions CHANGE action action ENUM('delete_field','add_field','update_field','move_field','copy_field','copy_and_replace_field')" ); + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 13560 - need an add option in marc modification templates)\n"; +} diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index f031503..5f33256 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -3568,7 +3568,7 @@ CREATE TABLE IF NOT EXISTS marc_modification_template_actions ( mmta_id int(11) NOT NULL AUTO_INCREMENT, template_id int(11) NOT NULL, ordering int(3) NOT NULL, - action ENUM('delete_field','update_field','move_field','copy_field','copy_and_replace_field') NOT NULL, + action ENUM('delete_field','add_field','update_field','move_field','copy_field','copy_and_replace_field') NOT NULL, field_number smallint(6) NOT NULL DEFAULT '0', from_field varchar(3) NOT NULL, from_subfield varchar(1) DEFAULT NULL, -- 2.1.4