From 657df01fec106e9a0e2afee7518c8b95537c93d4 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 4 Nov 2020 11:53:04 +0000 Subject: [PATCH] Bug 19482: DBRev 20.06.00.059 Signed-off-by: Jonathan Druart --- Koha.pm | 2 +- .../bug_19482_add_mandatory_field_to_mapping.perl | 10 ---------- installer/data/mysql/updatedatabase.pl | 10 ++++++++++ 3 files changed, 11 insertions(+), 11 deletions(-) delete mode 100644 installer/data/mysql/atomicupdate/bug_19482_add_mandatory_field_to_mapping.perl diff --git a/Koha.pm b/Koha.pm index c24d32a438..b1af032b21 100644 --- a/Koha.pm +++ b/Koha.pm @@ -29,7 +29,7 @@ use vars qw{ $VERSION }; # - #4 : the developer version. The 4th number is the database subversion. # used by developers when the database changes. updatedatabase take care of the changes itself # and is automatically called by Auth.pm when needed. -$VERSION = "20.06.00.058"; +$VERSION = "20.06.00.059"; sub version { return $VERSION; diff --git a/installer/data/mysql/atomicupdate/bug_19482_add_mandatory_field_to_mapping.perl b/installer/data/mysql/atomicupdate/bug_19482_add_mandatory_field_to_mapping.perl deleted file mode 100644 index 4fb8e51274..0000000000 --- a/installer/data/mysql/atomicupdate/bug_19482_add_mandatory_field_to_mapping.perl +++ /dev/null @@ -1,10 +0,0 @@ -$DBversion = 'XXX'; # will be replaced by the RM -if( CheckVersion( $DBversion ) ) { - - if( !column_exists( 'search_field', 'mandatory' ) ) { - $dbh->do( "ALTER TABLE search_field ADD COLUMN mandatory tinyint(1) NULL DEFAULT NULL AFTER opac" ); - } - - SetVersion( $DBversion ); - print "Upgrade to $DBversion done (Bug 19482 - Add mandatory column to search_field for ES mapping)\n"; -} diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index a922efa6d4..885e0b9bea 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -23183,6 +23183,16 @@ if( CheckVersion( $DBversion ) ) { NewVersion( $DBversion, 25333, q{Change message transport type for Talking Tech from "phone" to "itiva"}); } +$DBversion = '20.06.00.059'; +if( CheckVersion( $DBversion ) ) { + + if( !column_exists( 'search_field', 'mandatory' ) ) { + $dbh->do( "ALTER TABLE search_field ADD COLUMN mandatory tinyint(1) NULL DEFAULT NULL AFTER opac" ); + } + + NewVersion( $DBversion, 19482, "Add mandatory column to search_field for ES mapping" ); +} + # SEE bug 13068 # if there is anything in the atomicupdate, read and execute it. my $update_dir = C4::Context->config('intranetdir') . '/installer/data/mysql/atomicupdate/'; -- 2.39.5