From 90a711428188399f4ad6ff5f47f12a2c9d71c47f 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) --- installer/data/mysql/atomicupdate/bug_36396.pl | 16 ++++++++++++++++ installer/data/mysql/kohastructure.sql | 1 + 2 files changed, 17 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 00000000000..925057902d5 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_36396.pl @@ -0,0 +1,16 @@ +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 16310f0f449..55a3ea17934 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -5611,6 +5611,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.34.1