X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;ds=sidebyside;f=FS%2FFS%2Fcust_main.pm;h=dbb0144ff7b194ccf9769d422d34aaaeddb2083a;hb=7965de6cbd9f9795acc5fc27d6597a5ce63f6434;hp=da408246d9190649b3d92b836e525abe6a5f68ab;hpb=fb4ab1073f0d15d660c6cdc4e07afebf68ef3924;p=freeside.git diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm index da408246d..dbb0144ff 100644 --- a/FS/FS/cust_main.pm +++ b/FS/FS/cust_main.pm @@ -5036,6 +5036,8 @@ sub process_censustract_update { # then it's a tract code $cust_main->set('censustract', $new_tract); $cust_main->set('censusyear', $new_year); + + local($import) = 1; #prevent automatic geocoding (need its own variable?) my $error = $cust_main->replace; die $error if $error; } @@ -5063,6 +5065,10 @@ sub _upgrade_data { #class method "UPDATE cust_main SET paydate = SUBSTRING(paydate FROM 1 FOR 5) || '0' || SUBSTRING(paydate FROM 6) WHERE SUBSTRING(paydate FROM 7 FOR 1) = '-'"; } + push @statements, #fix the weird BILL with a cc# in payinfo problem + #DCRD to be safe, or CARD? + "UPDATE cust_main SET payby = 'DCRD' WHERE payby = 'BILL' and length(payinfo) = 16"; + foreach my $sql ( @statements ) { my $sth = dbh->prepare($sql) or die dbh->errstr; $sth->execute or die $sth->errstr;