allow open pay_batches to be included in search
[freeside.git] / httemplate / search / pay_batch.cgi
index 00c6ba1..620996a 100755 (executable)
@@ -150,8 +150,8 @@ my($begin, $end) = ( '', '' );
 my @where;
 
 my($beginning,$ending) = FS::UI::Web::parse_beginning_ending($cgi);
-push @where, "download >= $beginning",
-             "download <= $ending";
+push @where, "( (download >= $beginning AND download <= $ending) ".
+             ' OR download IS NULL )';
 
 my @status;
 if ( $cgi->param('open') ) {