X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2FUpgrade.pm;h=c856d95ed659e2af61b8715a060ca1a1904213d8;hb=252791a3e4a3cfdfef60e7278e06d899884f85a5;hp=97f24d403a6ac0a74efd55e3ea5b2afb9dac0502;hpb=078812ef1d27fc80e6bd4922bbe389e1e2048414;p=freeside.git diff --git a/FS/FS/Upgrade.pm b/FS/FS/Upgrade.pm index 97f24d403..c856d95ed 100644 --- a/FS/FS/Upgrade.pm +++ b/FS/FS/Upgrade.pm @@ -42,6 +42,10 @@ sub upgrade { my $data = upgrade_data(%opt); + my $oldAutoCommit = $FS::UID::AutoCommit; + local $FS::UID::AutoCommit = 0; + local $FS::UID::AutoCommit = 0; + foreach my $table ( keys %$data ) { my $class = "FS::$table"; @@ -53,13 +57,10 @@ sub upgrade { my $start = time; - my $oldAutoCommit = $FS::UID::AutoCommit; - local $FS::UID::AutoCommit = 0; - $FS::UID::AutoCommit = 0; - $class->_upgrade_data(%opt); if ( $oldAutoCommit ) { + warn " committing\n"; dbh->commit or die dbh->errstr; } @@ -91,12 +92,14 @@ sub upgrade_data { tie my %hash, 'Tie::IxHash', + #cust_main (remove paycvv from history) + 'cust_main' => [], + #msgcat 'msgcat' => [], #reason type and reasons 'reason_type' => [], - 'reason' => [], 'cust_pkg_reason' => [], #need part_pkg before cust_credit... @@ -123,9 +126,34 @@ sub upgrade_data { #usage_classes if we have none 'usage_class' => [], + #phone_type if we have none + 'phone_type' => [], + #fixup access rights 'access_right' => [], + #change recur_flat and enable_prorate + 'part_pkg_option' => [], + + #add weights to pkg_category + 'pkg_category' => [], + + #cdrbatch fixes + 'cdr' => [], + + #otaker->usernum + 'cust_attachment' => [], + #'cust_credit' => [], + #'cust_main' => [], + 'cust_main_note' => [], + #'cust_pay' => [], + 'cust_pay_void' => [], + 'cust_pkg' => [], + #'cust_pkg_reason' => [], + 'cust_pkg_discount' => [], + 'cust_refund' => [], + 'banned_pay' => [], + ; \%hash;