From 7aff89ebff30fa7f0973b00922a81f9b3b687935 Mon Sep 17 00:00:00 2001 From: Paul Poulain Date: Wed, 19 Sep 2012 12:01:11 +0200 Subject: [PATCH] Bug 7751 follow-up adding updatedatabase for sysprefs decreateLoanHighHolds* See http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7751#c31 to c34 --- installer/data/mysql/updatedatabase.pl | 9 +++++++++ kohaversion.pl | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 8f0efc80ea..f28995e3ec 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -5918,6 +5918,15 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { SetVersion ($DBversion); } +$DBversion = "3.09.00.052"; +if (C4::Context->preference("Version") < TransformToNum($DBversion)) { + $dbh->do("INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('decreaseLoanHighHolds', NULL, '', 'Decreases the loan period for items with number of holds above the threshold specified in decreaseLoanHighHoldsValue', 'YesNo');"); + $dbh->do("INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('decreaseLoanHighHoldsValue', NULL, '', 'Specifies a threshold for the minimum number of holds needed to trigger a reduction in loan duration (used with decreaseLoanHighHolds)', 'Integer');"); + $dbh->do("INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('decreaseLoanHighHoldsDuration', NULL, '', 'Specifies a number of days that a loan is reduced to when used in conjunction with decreaseLoanHighHolds', 'Integer');"); + print "Upgrade to $DBversion done (Add systempreferences to decrease loan length on high demand items decreaseLoanHighHolds, decreaseLoanHighHoldsValue and decreaseLoanHighHoldsDuration) \n"; + SetVersion ($DBversion); +} + =head1 FUNCTIONS diff --git a/kohaversion.pl b/kohaversion.pl index c796607986..1b810c3681 100644 --- a/kohaversion.pl +++ b/kohaversion.pl @@ -16,7 +16,7 @@ the kohaversion is divided in 4 parts : use strict; sub kohaversion { - our $VERSION = '3.09.00.051'; + our $VERSION = '3.09.00.052'; # version needs to be set this way # so that it can be picked up by Makefile.PL # during install -- 2.39.5