X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fprepay_credit.pm;h=a9d26d15176b9b3d9a57cf44aad5263f00760306;hb=c65b166b6e2ebdac5c2eb2e8336ebd1a4087f77c;hp=86274aa4c4266d64c7937aa1996df16220f5f2c3;hpb=959663cd4d4885295f44de43ac005e55d054102f;p=freeside.git diff --git a/FS/FS/prepay_credit.pm b/FS/FS/prepay_credit.pm index 86274aa4c..a9d26d151 100644 --- a/FS/FS/prepay_credit.pm +++ b/FS/FS/prepay_credit.pm @@ -21,6 +21,12 @@ FS::prepay_credit - Object methods for prepay_credit records 'amount' => '19.95', }; + $record = new FS::prepay_credit { + 'identifier' => '4198123455512121' + 'seconds' => '7200', + }; + + $error = $record->insert; $error = $new_record->replace($old_record); @@ -43,6 +49,8 @@ fields are currently supported: =item amount - amount of the credit +=item seconds - time amount of credit (see L) + =back =head1 METHODS @@ -96,31 +104,22 @@ sub check { $identifier =~ s/\W//g; #anything else would just confuse things $self->identifier($identifier); - $self->ut_number('prepaynum') + $self->ut_numbern('prepaynum') || $self->ut_alpha('identifier') || $self->ut_money('amount') + || $self->utnumbern('seconds') + || $self->SUPER::check ; } =back -=head1 VERSION - -$Id: prepay_credit.pm,v 1.1 2000-01-31 05:22:23 ivan Exp $ - =head1 BUGS =head1 SEE ALSO -L, schema.html from the base documentation. - -=head1 HISTORY - -$Log: prepay_credit.pm,v $ -Revision 1.1 2000-01-31 05:22:23 ivan -prepaid "internet cards" - +L, L, schema.html from the base documentation. =cut