Bug 12539: PROG/CCSR deprecation: Remove hardcoded theme from C4/Templates.pm
[koha-ffzg.git] / installer / data / mysql / updatedatabase.pl
index 3e6fa99..3739f38 100755 (executable)
@@ -8770,7 +8770,6 @@ if(CheckVersion($DBversion)) {
     SetVersion($DBversion);
 }
 
-
 $DBversion = '3.17.00.025';
 if ( CheckVersion($DBversion) ) {
     $dbh->do(qq{
@@ -8857,7 +8856,7 @@ if ( CheckVersion($DBversion) ) {
     SetVersion($DBversion);
 }
 
-$DBversion = "3.17.00.XXX";
+$DBversion = "3.17.00.033";
 if ( CheckVersion($DBversion) ) {
     $dbh->do(q{
         INSERT IGNORE INTO systempreferences (variable, value, explanation, options, type)
@@ -8867,6 +8866,59 @@ if ( CheckVersion($DBversion) ) {
     SetVersion($DBversion);
 }
 
+$DBversion = "3.17.00.034";
+if ( CheckVersion($DBversion) ) {
+    $dbh->do(q|
+        ALTER TABLE aqorders DROP COLUMN cancelledby;
+    |);
+
+    print "Upgrade to $DBversion done (Bug 11007 - DROP column aqorders.cancelledby)\n";
+    SetVersion($DBversion);
+}
+
+$DBversion = "3.17.00.035";
+if ( CheckVersion($DBversion) ) {
+    $dbh->do(q|
+        ALTER TABLE serial ADD COLUMN claims_count INT(11) DEFAULT 0 after claimdate
+    |);
+    $dbh->do(q|
+        UPDATE serial
+        SET claims_count = 1
+        WHERE claimdate IS NOT NULL
+    |);
+    print "Upgrade to $DBversion done (Bug 5342: Add claims_count field in serial table)\n";
+    SetVersion($DBversion);
+}
+
+$DBversion = "3.17.00.XXX";
+if ( CheckVersion($DBversion) ) {
+    $dbh->do("DELETE FROM systempreferences WHERE variable='OpacShowLibrariesPulldownMobile'");
+    print "Upgrade to $DBversion done ( Bug 12513 - PROG/CCSR deprecation: Remove OpacShowLibrariesPulldownMobile system preference )\n";
+    SetVersion ($DBversion);
+}
+
+$DBversion = "3.17.00.XXX";
+if ( CheckVersion($DBversion) ) {
+    $dbh->do("DELETE FROM systempreferences WHERE variable='OpacMainUserBlockMobile'");
+    print "Upgrade to $DBversion done ( Bug 12246 - PROG/CCSR deprecation: Remove OpacMainUserBlockMobile system preference )\n";
+    SetVersion ($DBversion);
+}
+
+$DBversion = "3.17.00.XXX";
+if ( CheckVersion($DBversion) ) {
+    $dbh->do("DELETE FROM systempreferences WHERE variable='OPACMobileUserCSS'");
+    print "Upgrade to $DBversion done ( Bug 12245 - PROG/CCSR deprecation: Remove OPACMobileUserCSS system preference )\n";
+    SetVersion ($DBversion);
+}
+
+$DBversion = "3.17.00.XXX";
+if ( CheckVersion($DBversion) ) {
+    $dbh->do("INSERT IGNORE INTO systempreferences (variable, value, options, explanation, type) VALUES
+    ('OPACFallback', 'prog', 'bootstrap|prog', 'Define the fallback theme for the OPAC interface.', 'Themes')");
+    print "Upgrade to $DBversion done (Bug 12539 - PROG/CCSR deprecation: Remove hardcoded theme from C4/Templates.pm)\n";
+    SetVersion ($DBversion);
+}
+
 =head1 FUNCTIONS
 
 =head2 TableExists($table)