X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2FUpgrade.pm;h=c856d95ed659e2af61b8715a060ca1a1904213d8;hb=55375c203e5d337e232041e368869a6336f1fd26;hp=8cc5c61b879985e5a89fe65a0480e60ae70d58e7;hpb=03ceab71dad1e5eb366865d304e5e459cc905ce4;p=freeside.git diff --git a/FS/FS/Upgrade.pm b/FS/FS/Upgrade.pm index 8cc5c61b8..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; } @@ -99,7 +100,6 @@ sub upgrade_data { #reason type and reasons 'reason_type' => [], - 'reason' => [], 'cust_pkg_reason' => [], #need part_pkg before cust_credit... @@ -132,9 +132,6 @@ sub upgrade_data { #fixup access rights 'access_right' => [], - #change tax_rate column types - 'tax_rate' => [], - #change recur_flat and enable_prorate 'part_pkg_option' => [], @@ -144,6 +141,19 @@ sub upgrade_data { #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;