From 9bf384ba96beced2721cd15a0a639074ab2c2749 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Fri, 11 Oct 2019 10:57:30 +0100 Subject: [PATCH] Bug 17140: DBRev 19.05.04.001 Signed-off-by: Martin Renvoize (cherry picked from commit 9d9bb45865c9d6c88952f47f52f0e92ddcce0054) Signed-off-by: Fridolin Somers --- Koha.pm | 2 +- ...ug_17140_add_pref_to_round_fines_at_payment.perl | 12 ------------ installer/data/mysql/updatedatabase.pl | 13 +++++++++++++ 3 files changed, 14 insertions(+), 13 deletions(-) delete mode 100644 installer/data/mysql/atomicupdate/bug_17140_add_pref_to_round_fines_at_payment.perl diff --git a/Koha.pm b/Koha.pm index 968b64616a..f361a6a264 100644 --- 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 = "19.05.04.000"; +$VERSION = "19.05.04.001"; sub version { return $VERSION; diff --git a/installer/data/mysql/atomicupdate/bug_17140_add_pref_to_round_fines_at_payment.perl b/installer/data/mysql/atomicupdate/bug_17140_add_pref_to_round_fines_at_payment.perl deleted file mode 100644 index b80aa610ea..0000000000 --- a/installer/data/mysql/atomicupdate/bug_17140_add_pref_to_round_fines_at_payment.perl +++ /dev/null @@ -1,12 +0,0 @@ -$DBversion = 'XXX'; # will be replaced by the RM -if( CheckVersion( $DBversion ) ) { - $dbh->do(q| - INSERT IGNORE INTO systempreferences - (variable,value,explanation,options,type) - VALUES - ('RoundFinesAtPayment','0','If enabled any fines with fractions of a cent will be rounded to the nearest cent when payments are collected. e.g. 1.004 will be paid off by a 1.00 payment','0','YesNo') - |); - - SetVersion( $DBversion ); - print "Upgrade to $DBversion done (Bug 17140 - Add pref to allow rounding fines at payment)\n"; -} diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 2d51cfda0d..9e47d409de 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -18815,6 +18815,19 @@ if( CheckVersion( $DBversion ) ) { print "Upgrade to $DBversion done (19.05.04 release)\n"; } +$DBversion = '19.05.04.001'; +if( CheckVersion( $DBversion ) ) { + $dbh->do(q| + INSERT IGNORE INTO systempreferences + (variable,value,explanation,options,type) + VALUES + ('RoundFinesAtPayment','0','If enabled any fines with fractions of a cent will be rounded to the nearest cent when payments are collected. e.g. 1.004 will be paid off by a 1.00 payment','0','YesNo') + |); + + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 17140 - Add pref to allow rounding fines at payment)\n"; +} + # SEE bug 13068 # if there is anything in the atomicupdate, read and execute it. -- 2.20.1