Bug 20815: DBRev 20.06.00.010
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 23 Jul 2020 08:30:31 +0000 (10:30 +0200)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 23 Jul 2020 08:52:10 +0000 (10:52 +0200)
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Koha.pm
installer/data/mysql/atomicupdate/bug_20815.perl [deleted file]
installer/data/mysql/updatedatabase.pl

diff --git a/Koha.pm b/Koha.pm
index 3d576bf..b7b3b34 100644 (file)
--- 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.009";
+$VERSION = "20.06.00.010";
 
 sub version {
     return $VERSION;
diff --git a/installer/data/mysql/atomicupdate/bug_20815.perl b/installer/data/mysql/atomicupdate/bug_20815.perl
deleted file mode 100644 (file)
index 9f5d451..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-$DBversion = 'XXX'; # will be replaced by the RM
-if( CheckVersion( $DBversion ) ) {
-    $dbh->do(q{
-        INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES
-        ('NoRefundOnLostReturnedItemsAge','','','Do not refund lost item fees if item is lost for more than this number of days','Integer')
-    });
-
-    SetVersion( $DBversion );
-    print "Upgrade to $DBversion done (Bug 20815: Add NoRefundOnLostReturnedItemsAge system preference)\n";
-}
index d2e18f7..348b797 100755 (executable)
@@ -22346,6 +22346,16 @@ if( CheckVersion( $DBversion ) ) {
     NewVersion( $DBversion, 23391, "Hide finished ILL requests" );
 }
 
+$DBversion = '20.06.00.010';
+if( CheckVersion( $DBversion ) ) {
+    $dbh->do(q{
+        INSERT IGNORE INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `type` ) VALUES
+        ('NoRefundOnLostReturnedItemsAge','','','Do not refund lost item fees if item is lost for more than this number of days','Integer')
+    });
+
+    NewVersion( $DBversion, 20815, "Add NoRefundOnLostReturnedItemsAge system preference" );
+}
+
 # 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/';