diff options
author | ivan <ivan> | 2007-06-09 00:43:14 +0000 |
---|---|---|
committer | ivan <ivan> | 2007-06-09 00:43:14 +0000 |
commit | 893a697cfa7c60c9663057a02a251e7397813acc (patch) | |
tree | acc96673b4b19faca9a3b83e1f4044cdfb6cbb81 /FS/FS/Cron/bill.pm | |
parent | 72b2e7ea624fe1a436ffdd325df83ac7c1f193f0 (diff) |
skycatcher modifications for pre-printing invoices, but with today's date
Diffstat (limited to 'FS/FS/Cron/bill.pm')
-rw-r--r-- | FS/FS/Cron/bill.pm | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/FS/FS/Cron/bill.pm b/FS/FS/Cron/bill.pm index 4d77fd08d..9926fea9e 100644 --- a/FS/FS/Cron/bill.pm +++ b/FS/FS/Cron/bill.pm @@ -24,6 +24,8 @@ sub bill { my($time)= $opt{'d'} ? str2time($opt{'d'}) : $^T; $time += $opt{'y'} * 86400 if $opt{'y'}; + my $invoice_time = $opt{'n'} ? $^T : $time; + # select * from cust_main where my $where_pkg = <<"END"; 0 < ( select count(*) from cust_pkg @@ -102,8 +104,9 @@ END if $error; } - my $error = $cust_main->bill( 'time' => $time, - 'resetup' => $opt{'s'}, + my $error = $cust_main->bill( 'time' => $time, + 'invoice_time' => $invoice_time, + 'resetup' => $opt{'s'}, ); warn "Error billing, custnum ". $cust_main->custnum. ": $error" if $error; |