6 The <b>freeside-bill</b> script can be run daily to bill all customers. Usage: bill [ -c [ i ] ] [ -d <i>date</i> ] [ -b ] <i>user</i>
8 <li>-c: Turn on collecting (you probably want this).
9 <li>-i: Real-time billing (as opposed to bacth billing). Only relevant for credit cards.
10 <li>-d: Pretend it is <i>date</i> (parsed by Date::Parse)
13 Printing should be configured on your freeside machine to print invoices.
14 <br><br>Batch credit card processing
16 <li>After this script is run, a credit card batch will be in the <a href="schema.html#cust_pay_batch">cust_pay_batch</a> table. Export this table to your credit card batching.
17 <li>When your batch completes, erase the cust_pay_batch records in that batch and add any necessary paymants to the <a href="schema.html#cust_pay">cust_pay</a> table. Example code to add payments is:
18 <pre>use FS::cust_pay;
20 # loop over all records in batch
22 my $payment=create FS::cust_pay (
27 'payinfo' => $payinfo,
28 'paybatch' => $paybatch,
31 my $error=$payment->insert;
38 All fields except paybatch are contained in the cust_pay_batch table. You can use paybatch field to track particular batches and/or particular transactions within a batch.<br><br>
39 <li>The <b>freeside-print-batch</b> script can print or email pending credit card batches for manual entry. Usage: freeside-print-batch [-v] [-p] [-e] [-a] [-d] <i>user</i>
41 <li>-v: Verbose - Prints records to STDOUT.
42 <li>-p: Print to printer lpr as found in the conf directory.
43 <li>-e: Email output to user found in the Conf email file.
44 <li>-a: Automatically pays all records in cust_pay_batch. Use -d with this option usually.
45 <li>-d: Delete - Pays account and deletes record from cust_pay_batch.