X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=FS%2Fbin%2Ffreeside-rbc-upload;h=37036b0bbf4cfa1d16308f63d9e387a13d04e8a5;hp=52501028cb4a1ebd4165afdb07c1786bf735f21e;hb=7c079bd8cb5ccf5381ac0c054438efcd0645ddbf;hpb=038ad47addd4168c74165c4a79051e4d2599258e diff --git a/FS/bin/freeside-rbc-upload b/FS/bin/freeside-rbc-upload index 52501028c..37036b0bb 100755 --- a/FS/bin/freeside-rbc-upload +++ b/FS/bin/freeside-rbc-upload @@ -33,6 +33,7 @@ my @batches; if($opt_a) { my %criteria = (status => 'O'); $criteria{'payby'} = uc($opt_p) if $opt_p; + $criteria{'type'} = 'DEBIT' unless FS::pay_batch->can_handle_electronic_refunds('RBC'); @batches = qsearch('pay_batch', \%criteria); die "No open batches found".($opt_p ? " of type '$opt_p'" : '').".\n" if !@batches;