=item _date - specified as a UNIX timestamp; see L<perlfunc/"time">. Also see
L<Time::Local> and L<Date::Parse> for conversion functions.
-=item payby - `CARD' (credit cards), `BILL' (billing), or `COMP' (free)
+=item payby - `CARD' (credit cards), `CHEK' (electronic check/ACH),
+`LECB' (Phone bill billing), `BILL' (billing), or `COMP' (free)
=item payinfo - card number, P.O.#, or comp issuer (4-8 lowercase alphanumerics; think username)
my $dbh = dbh;
if ( $self->crednum ) {
- my $cust_credit = qsearchs('cust_bill', { 'invnum' => $self->invnum } )
+ my $cust_credit = qsearchs('cust_credit', { 'crednum' => $self->crednum } )
or do {
$dbh->rollback if $oldAutoCommit;
return "Unknown cust_credit.crednum: ". $self->crednum;
my $self = shift;
my $error =
- $self->ut_number('refundnum')
+ $self->ut_numbern('refundnum')
|| $self->ut_numbern('custnum')
|| $self->ut_money('refund')
|| $self->ut_numbern('_date')
unless $self->crednum
|| qsearchs( 'cust_main', { 'custnum' => $self->custnum } );
- $self->payby =~ /^(CARD|BILL|COMP)$/ or return "Illegal payby";
+ $self->payby =~ /^(CARD|CHEK|LECB|BILL|COMP)$/ or return "Illegal payby";
$self->payby($1);
#false laziness with cust_pay::check
=head1 VERSION
-$Id: cust_refund.pm,v 1.16 2002-02-19 03:06:23 ivan Exp $
+$Id: cust_refund.pm,v 1.20 2002-11-19 09:51:58 ivan Exp $
=head1 BUGS