bug 3756: remove disused system preference from database
authorGalen Charlton <gmcharlt@gmail.com>
Fri, 22 Oct 2010 01:50:27 +0000 (21:50 -0400)
committerGalen Charlton <gmcharlt@gmail.com>
Fri, 22 Oct 2010 01:53:13 +0000 (21:53 -0400)
This leaves a few system preferences displayed on the
local use tab in the syspref editor that should be displayed
elsewhere, but all of the ones left are actually in use.

Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
installer/data/mysql/updatedatabase.pl
kohaversion.pl

index af13b51..cf0c407 100755 (executable)
@@ -3752,6 +3752,29 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
     SetVersion ($DBversion);
 }
 
+$DBversion = "3.02.00.001";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+    $dbh->do(q{DELETE FROM systempreferences WHERE variable IN (
+                'holdCancelLength',
+                'PINESISBN',
+                'sortbynonfiling',
+                'TemplateEncoding',
+                'OPACSubscriptionDisplay',
+                'OPACDisplayExtendedSubInfo',
+                'OAI-PMH:Set',
+                'OAI-PMH:Subset',
+                'ILS-DI:AuthorizedIPs',
+                'libraryAddress',
+                'kohaspsuggest',
+                'OrderPdfTemplate',
+                'marc',
+                'acquisitions',
+                'MIME')
+               }
+    );
+    print "Upgrade to $DBversion done (bug 3756: remove disused system preferences)\n";
+    SetVersion ($DBversion);
+}
 
 =item DropAllForeignKeys($table)
 
index f5e35ac..b231acd 100644 (file)
@@ -10,7 +10,7 @@
 use strict;
 
 sub kohaversion {
-    our $VERSION = '3.02.00.000';
+    our $VERSION = '3.02.00.001';
     # version needs to be set this way
     # so that it can be picked up by Makefile.PL
     # during install