X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Fcust_main.cgi;h=c72ab44df191ea25753689ef968bb1a19424bf20;hb=a0732f52fdcc2bca7c399d1249ccceb191de51cd;hp=7d5941a16d42abd2b714fffe6d67c3ea66944d38;hpb=a59c9cdd72fdf85d81007ba86e81479f6ec8e6e5;p=freeside.git diff --git a/httemplate/search/cust_main.cgi b/httemplate/search/cust_main.cgi index 7d5941a16..c72ab44df 100755 --- a/httemplate/search/cust_main.cgi +++ b/httemplate/search/cust_main.cgi @@ -109,6 +109,7 @@ if ( $cgi->param('browse') push @qual, FS::cust_main->cancel_sql if $cgi->param('cancelled'); push @qual, FS::cust_main->prospect_sql if $cgi->param('prospect'); push @qual, FS::cust_main->active_sql if $cgi->param('active'); + push @qual, FS::cust_main->inactive_sql if $cgi->param('inactive'); push @qual, FS::cust_main->susp_sql if $cgi->param('suspended'); #EWWWWWW @@ -415,48 +416,78 @@ END foreach my $addl_col ( @addl_cols ) { %> - ALIGN=right> - - <% if ( $addl_col eq 'tickets' ) { - if ( @custom_priorities ) { - print &itable('', 0); - foreach my $priority ( @custom_priorities, '' ) { - - my $num = - FS::TicketSystem->num_customer_tickets($custnum,$priority); - my $ahref = ''; - $ahref= '' - if $num; - - print ''. - " $ahref$num". - "$ahref". - ( $priority || '(none)' ). - ""; - - } - print ''. - ''; - } - - my $ahref = ''; - $ahref = '' - if $cust_main->get($addl_col); - - print $ahref. $cust_main->get($addl_col). ''; - print "". - "${ahref}Total". - "" - if @custom_priorities; + <% if ( $addl_col eq 'tickets' ) { %> - } else { - print $cust_main->get($addl_col); + <% if ( @custom_priorities ) { %> + + ALIGN=right> + + + + <% foreach my $priority ( @custom_priorities, '' ) { %> + + <% + my $num = + FS::TicketSystem->num_customer_tickets($custnum,$priority); + my $ahref = ''; + $ahref= '' + if $num; + %> + + + + + + + <% } %> + + + + +
+ <%= $ahref.$num %> + + <%= $ahref %><%= $priority || '(none)' %> +
+ + + <% } else { %> + + ALIGN=right> + + <% } %> + + <% + my $ahref = ''; + $ahref = '' + if $cust_main->get($addl_col); + %> + + <%= $ahref %><%= $cust_main->get($addl_col) %> + + <% if ( @custom_priorities ) { %> + + + + <%= ${ahref} %>Total +
+ + <% } %> + +
+ + } else { %> + + ALIGN=right> + <%= $cust_main->get($addl_col) %> + + +<% } - print "
"; } my($n1)='';