View | Details | Raw Unified | Return to bug 38769
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/bug_38769.pl (+23 lines)
Line 0 Link Here
1
use Modern::Perl;
2
use Koha::Installer::Output qw(say_warning say_success say_info);
3
4
return {
5
    bug_number  => "38769",
6
    description => "Add consents column to borrower_modifications for plugin consent storage",
7
    up          => sub {
8
        my ($args) = @_;
9
        my ( $dbh, $out ) = @$args{qw(dbh out)};
10
11
        unless ( column_exists( 'borrower_modifications', 'consents' ) ) {
12
            $dbh->do(
13
                q{
14
                ALTER TABLE borrower_modifications
15
                ADD COLUMN `consents` mediumtext DEFAULT NULL
16
                COMMENT 'JSON-encoded plugin consents for self-registration'
17
                AFTER `extended_attributes`
18
            }
19
            );
20
            say $out "Added column 'borrower_modifications.consents'";
21
        }
22
    },
23
};
(-)a/installer/data/mysql/kohastructure.sql (-1 / +1 lines)
Lines 1477-1482 CREATE TABLE `borrower_modifications` ( Link Here
1477
  `smsalertnumber` varchar(50) DEFAULT NULL,
1477
  `smsalertnumber` varchar(50) DEFAULT NULL,
1478
  `privacy` int(11) DEFAULT NULL,
1478
  `privacy` int(11) DEFAULT NULL,
1479
  `extended_attributes` mediumtext DEFAULT NULL,
1479
  `extended_attributes` mediumtext DEFAULT NULL,
1480
  `consents` mediumtext DEFAULT NULL COMMENT 'JSON-encoded plugin consents for self-registration',
1480
  `gdpr_proc_consent` datetime DEFAULT NULL COMMENT 'data processing consent',
1481
  `gdpr_proc_consent` datetime DEFAULT NULL COMMENT 'data processing consent',
1481
  `primary_contact_method` varchar(45) DEFAULT NULL COMMENT 'useful for reporting purposes',
1482
  `primary_contact_method` varchar(45) DEFAULT NULL COMMENT 'useful for reporting purposes',
1482
  `lang` varchar(25) DEFAULT NULL,
1483
  `lang` varchar(25) DEFAULT NULL,
1483
- 

Return to bug 38769