From a3887fe12af6979bef92be3025fbaabc09e6f1e0 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 21 Mar 2024 15:45:11 +0100 Subject: [PATCH] Bug 36396: DB changes Add the new DB column search_field.authorised_value_category Sponsored-by: The Research University in the Helmholtz Association (KIT) Signed-off-by: Lukas Koszyk Signed-off-by: Martin Renvoize Signed-off-by: Katrin Fischer --- installer/data/mysql/atomicupdate/bug_36396.pl | 18 ++++++++++++++++++ installer/data/mysql/kohastructure.sql | 1 + 2 files changed, 19 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug_36396.pl diff --git a/installer/data/mysql/atomicupdate/bug_36396.pl b/installer/data/mysql/atomicupdate/bug_36396.pl new file mode 100755 index 0000000000..ad78feb7da --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_36396.pl @@ -0,0 +1,18 @@ +use Modern::Perl; + +return { + bug_number => "36396", + description => "Link elastic facets with authorized value categories", + up => sub { + my ($args) = @_; + my ( $dbh, $out ) = @$args{qw(dbh out)}; + + $dbh->do( + q{ + ALTER TABLE search_field + ADD COLUMN `authorised_value_category` varchar(32) DEFAULT NULL + AFTER mandatory + } + ); + }, +}; diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index 54f739f6c9..5ddc93703b 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -5653,6 +5653,7 @@ CREATE TABLE `search_field` ( `staff_client` tinyint(1) NOT NULL DEFAULT 1, `opac` tinyint(1) NOT NULL DEFAULT 1, `mandatory` tinyint(1) DEFAULT NULL COMMENT 'if marked this field is not editable or removable', + `authorised_value_category` varchar(32) DEFAULT NULL COMMENT 'link to authorised value category', PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`(191)) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; -- 2.39.5