default to a session cookie instead of setting an explicit timeout, weird timezone...
[freeside.git] / httemplate / search / cust_credit.html
index 4de50a0..88f9bca 100755 (executable)
@@ -43,6 +43,15 @@ $show_voided_credits = $cgi->param('show_voided_credits')
 my (@header, @fields, @sort_fields, $align, @links, @color, @style);
 $align = '';
 
+# Report Column: crednum
+push @header, emt('Ref No');
+push @fields, sub { shift->crednum };
+push @sort_fields, '';
+$align .= 'l';
+push @links, '';
+push @color, '';
+push @style, '';
+
 # Report Column: Amount
 push @header, emt('Amount');
 push @fields, sub { $money_char .sprintf('%.2f', shift->amount) };
@@ -186,6 +195,10 @@ if ( $cgi->param('credbatch') =~ /^([\w\-\/\.\:]+)$/ ) {
   push @search, "cust_credit.credbatch = '$1'";
 }
 
+if ( $cgi->param('reasonnum') =~ /^(\d+)$/ && $1 ) {
+  push @search, "cust_credit.reasonnum = $1";
+}
+
 # commission_salesnum
 if ( $cgi->param('commission_salesnum') =~ /^(\d+)$/ ) {
   push @search, "commission_salesnum = $1";