[Koha-patches] [PATCH] bug 3923 followup - change orderpdfformat value if set wrong due to upgrade
Nicole Engard
nengard at gmail.com
Fri Feb 5 11:23:42 CET 2010
---
installer/data/mysql/updatedatabase.pl | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl
index e1a59c0..521e381 100755
--- a/installer/data/mysql/updatedatabase.pl
+++ b/installer/data/mysql/updatedatabase.pl
@@ -3398,6 +3398,15 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
SetVersion ($DBversion);
}
+$DBversion = 'XXX';
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ if (C4::Context->preference('OrderPdfFormat') eq 'pdfformat::example'){
+ $dbh->do("UPDATE `systempreferences` set value='pdfformat::layout2pages' WHERE variable='OrderPdfFormat'");
+ }
+ print "Upgrade done ( corrected default OrderPdfFormat value is still set wrong )\n";
+ SetVersion ($DBversion);
+}
+
=item DropAllForeignKeys($table)
Drop all foreign keys of the table $table
--
1.5.6.5
More information about the Koha-patches
mailing list