Difference between revisions of "Freeside:4:Documentation:Developer/FS/cust bill pay"

From Freeside
Jump to: navigation, search
(Edit via perl MediaWiki framework (1.13))
 
(No difference)

Latest revision as of 07:19, 18 November 2015

NAME

FS::cust_bill_pay - Object methods for cust_bill_pay records

SYNOPSIS

 use FS::cust_bill_pay;

 $record = new FS::cust_bill_pay \%hash;
 $record = new FS::cust_bill_pay { 'column' => 'value' };

 $error = $record->insert;

 $error = $new_record->replace($old_record);

 $error = $record->delete;

 $error = $record->check;

DESCRIPTION

An FS::cust_bill_pay object represents the application of a payment to a specific invoice. FS::cust_bill_pay inherits from FS::cust_bill_ApplicationCommon and FS::Record. The following fields are currently supported:

billpaynum - primary key (assigned automatically); invnum - Invoice (see FS::cust_bill); paynum - Payment (see FS::cust_pay); amount - Amount of the payment to apply to the specific invoice.; _date - specified as a UNIX timestamp; see "time" in perlfunc. Also see Time::Local and Date::Parse for conversion functions.

METHODS

new HASHREF
Creates a new record. To add the record to the database, see "insert".
insert
Adds this record to the database. If there is an error, returns the error, otherwise returns false.
delete
Deletes this payment application, unless the closed flag for the parent payment (see FS::cust_pay) is set.
replace OLD_RECORD
Currently unimplemented (accounting reasons).
check
Checks all fields to make sure this is a valid payment application. If there is an error, returns the error, otherwise returns false. Called by the insert method.
cust_pay
Returns the payment (see FS::cust_pay)
send_receipt HASHREF | OPTION => VALUE ...
Sends a payment receipt for the associated payment, against this specific invoice. If there is an error, returns the error, otherwise returns false.
See "send receipt" in FS/cust pay|FS::cust_pay#send_receipt|"send_receipt" in FS::cust_pay.

BUGS

Delete and replace methods.

SEE ALSO

FS::cust_pay, FS::cust_bill, FS::Record, schema.html from the base documentation.