From: mark Date: Thu, 10 Feb 2011 06:08:30 +0000 (+0000) Subject: fix batch payment recording again X-Git-Tag: freeside_2_3_0~629 X-Git-Url: http://git.freeside.biz/gitweb/?a=commitdiff_plain;h=774bbec9e4f6ad5aff02c1d64b6d3e48d594279e;p=freeside.git fix batch payment recording again --- diff --git a/FS/FS/pay_batch.pm b/FS/FS/pay_batch.pm index 9bec2c794..5ccad5bf1 100644 --- a/FS/FS/pay_batch.pm +++ b/FS/FS/pay_batch.pm @@ -354,14 +354,14 @@ sub import_results { &{$hook}(\%hash, $cust_pay_batch->hashref); - my $new_cust_pay_batch = new FS::cust_pay_batch { - $cust_pay_batch->hash, - %hash - }; + my $new_cust_pay_batch = new FS::cust_pay_batch { $cust_pay_batch->hash }; my $error = ''; if ( &{$approved_condition}(\%hash) ) { + foreach ('paid', '_date', 'payinfo') { + $new_cust_pay_batch->$_($hash{$_}) if $hash{$_}; + } $error = $new_cust_pay_batch->approve($hash{'paybatch'} || $self->batchnum); $total += $hash{'paid'};