Bug 22844: DBRev 20.06.00.007

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Jonathan Druart 2020-07-20 16:05:38 +02:00
parent d23d9f931a
commit 2fb5f3624e
3 changed files with 14 additions and 15 deletions

View File

@ -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.006";
$VERSION = "20.06.00.007";
sub version {
return $VERSION;

View File

@ -1,14 +0,0 @@
$DBversion = 'XXX'; # will be replaced by the RM
if( CheckVersion( $DBversion ) ) {
if( !column_exists( 'borrower_attribute_types', 'mandatory' ) ) {
$dbh->do(q|
ALTER TABLE borrower_attribute_types
ADD COLUMN mandatory TINYINT(1) NOT NULL DEFAULT 0
AFTER keep_for_pseudonymization
|);
}
SetVersion( $DBversion );
print "Upgrade to $DBversion done (Bug XXXXX - Add borrower_attribute_types.mandatory)\n";
}

View File

@ -22316,6 +22316,19 @@ if( CheckVersion( $DBversion ) ) {
NewVersion( $DBversion, 24151, "Add pseudonymized_transactions tables and sysprefs for Pseudonymization" );
}
$DBversion = '20.06.00.007';
if( CheckVersion( $DBversion ) ) {
if( !column_exists( 'borrower_attribute_types', 'mandatory' ) ) {
$dbh->do(q|
ALTER TABLE borrower_attribute_types
ADD COLUMN mandatory TINYINT(1) NOT NULL DEFAULT 0
AFTER keep_for_pseudonymization
|);
}
NewVersion( $DBversion, 22844, "Add borrower_attribute_types.mandatory" );
}
# 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/';