fix "Invoice is newer than last payment type change" condition, RT#33766
authorIvan Kohler <ivan@freeside.biz>
Wed, 3 Jun 2015 22:24:09 +0000 (15:24 -0700)
committerIvan Kohler <ivan@freeside.biz>
Wed, 3 Jun 2015 22:24:09 +0000 (15:24 -0700)
FS/FS/part_event/Condition/cust_bill_age_before_payby.pm

index 96d9da8..5a81fbb 100644 (file)
@@ -34,12 +34,12 @@ sub condition {
             'order_by' => 'ORDER BY history_date DESC LIMIT 1',
         }))
   {
-    my $newest = $replace_new->history_date;
+    $newest = $replace_new->history_date;
     my $replace_old = qsearchs({
       'table' => 'h_cust_main',
       'hashref' => { 'custnum'        => $replace_new->custnum,
                      'history_action' => 'replace_old',
-                     'history_date'   => $replace_new->history_date,
+                     'history_date'   => $replace_new->history_date, #fuzz?
                    }
     }) or next; #no replace_old?  ignore and continue on i guess