X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2FCron%2Fbill.pm;h=2c9468b14fd9840d2c77c364bfd6c660393099d0;hb=0617a36106148efd7884c2f6ccd2a41075f9e5f6;hp=d3f1eb42b1fa7f7a74d5a5d7e2585a6aa3272648;hpb=4f335eca5fd1efa2c823d461f7e34feded4e4990;p=freeside.git

diff --git a/FS/FS/Cron/bill.pm b/FS/FS/Cron/bill.pm
index d3f1eb42b..2c9468b14 100644
--- a/FS/FS/Cron/bill.pm
+++ b/FS/FS/Cron/bill.pm
@@ -161,8 +161,6 @@ sub bill {
 #      with today's date, regardless of the pretend date used to pre-generate
 #      the invoices.
 #
-#  -p: Only process customers with the specified payby (I<CARD>, I<DCRD>, I<CHEK>, I<DCHK>, I<BILL>, I<COMP>, I<LECB>)
-#
 #  -a: Only process customers with the specified agentnum
 #
 #  -v: enable debugging
@@ -190,8 +188,6 @@ sub bill_where {
 
   push @search, "( cust_main.archived != 'Y' OR archived IS NULL )"; #disable?
 
-  push @search, "cust_main.payby    = '". $opt{'p'}. "'"
-    if $opt{'p'};
   push @search, "cust_main.agentnum IN ( ". $opt{'a'}. " ) "
     if $opt{'a'};
 
@@ -236,7 +232,8 @@ END
     my $eventtable = $_;
 
     # joins and where clauses to test event conditions
-    my $join  = FS::part_event_condition->join_conditions_sql(  $eventtable );
+    my $join  = FS::part_event_condition->join_conditions_sql(  $eventtable,
+                                                                'time'=>$time );
     my $where = FS::part_event_condition->where_conditions_sql( $eventtable,
                                                                 'time'=>$time,
                                                               );