From e5dbc76fff52c63695b3670667e73a95c3309402 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Mon, 29 Apr 2019 16:09:00 +0000 Subject: [PATCH] Bug 8995: DBRev 18.12.00.066 Signed-off-by: Nick Clemens --- Koha.pm | 2 +- installer/data/mysql/atomicupdate/bug_8995.perl | 15 --------------- installer/data/mysql/updatedatabase.pl | 16 ++++++++++++++++ t/db_dependent/Biblio.t | 2 +- 4 files changed, 18 insertions(+), 17 deletions(-) delete mode 100644 installer/data/mysql/atomicupdate/bug_8995.perl diff --git a/Koha.pm b/Koha.pm index 19e1eba259..c936645b85 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 = "18.12.00.065"; +$VERSION = "18.12.00.066"; sub version { return $VERSION; diff --git a/installer/data/mysql/atomicupdate/bug_8995.perl b/installer/data/mysql/atomicupdate/bug_8995.perl deleted file mode 100644 index d1fd16a5dd..0000000000 --- a/installer/data/mysql/atomicupdate/bug_8995.perl +++ /dev/null @@ -1,15 +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 - ('OpenURLResolverURL', '', 'URL of OpenURL Resolver', NULL, 'Free'), - ('OpenURLText', '', 'Text of OpenURL links (or image title if OpenURLImageLocation is defined)', NULL, 'Free'), - ('OpenURLImageLocation', '', 'Location of image for OpenURL links', NULL, 'Free'), - ('OPACShowOpenURL', '', 'Enable display of OpenURL links in OPAC search results and detail page', NULL, 'YesNo'), - ('OPACOpenURLItemTypes', '', 'Show the OpenURL link only for these item types', NULL, 'Free'); - }); - - SetVersion($DBversion); - print -"Upgrade to $DBversion done (Bug 8995 - Add new preferences for OpenURLResolvers)\n"; -} diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index c077f73587..6d69219162 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -18395,6 +18395,22 @@ if( CheckVersion( $DBversion ) ) { print "Upgrade to $DBversion done (Bug 10300 - Allow transferring of items to be have separate IndependentBranches syspref)\n"; } +$DBversion = '18.12.00.066'; +if ( CheckVersion($DBversion) ) { + $dbh->do(q{ + INSERT IGNORE INTO `systempreferences` (`variable`, `value`, `explanation`, `options`, `type`) VALUES + ('OpenURLResolverURL', '', 'URL of OpenURL Resolver', NULL, 'Free'), + ('OpenURLText', '', 'Text of OpenURL links (or image title if OpenURLImageLocation is defined)', NULL, 'Free'), + ('OpenURLImageLocation', '', 'Location of image for OpenURL links', NULL, 'Free'), + ('OPACShowOpenURL', '', 'Enable display of OpenURL links in OPAC search results and detail page', NULL, 'YesNo'), + ('OPACOpenURLItemTypes', '', 'Show the OpenURL link only for these item types', NULL, 'Free'); + }); + + SetVersion($DBversion); + print +"Upgrade to $DBversion done (Bug 8995 - Add new preferences for OpenURLResolvers)\n"; +} + # SEE bug 13068 # if there is anything in the atomicupdate, read and execute it. diff --git a/t/db_dependent/Biblio.t b/t/db_dependent/Biblio.t index 66f9c961ad..dd96e546ff 100755 --- a/t/db_dependent/Biblio.t +++ b/t/db_dependent/Biblio.t @@ -17,7 +17,7 @@ use Modern::Perl; -use Test::More tests => 11; +use Test::More tests => 12; use Test::MockModule; use List::MoreUtils qw( uniq ); use MARC::Record; -- 2.20.1