1 <% $link %><% $pre %>Invoice #<% $invnum %>
2 (Balance $ <% $cust_bill->owed %>)<% $post %><% $link ? '</A>' : '' %><% $events %>
5 my( $cust_bill, %opt ) = @_;
7 my $curuser = $FS::CurrentUser::CurrentUser;
9 my($pre, $post) = ('', '');
10 if ( $cust_bill->owed > 0 ) {
11 $pre = '<B><FONT SIZE="+1" COLOR="#FF0000">Open ';
12 $post = '</FONT></B>';
15 my $invnum = $cust_bill->invnum;
17 my $link = $curuser->access_right('View invoices')
18 ? qq!<A HREF="${p}view/cust_bill.cgi?$invnum">!
23 if ( $cust_bill->num_cust_event
24 && ( $curuser->access_right('Billing event reports')
25 || $curuser->access_right('View customer billing events')
29 qq!<BR><FONT SIZE="-1"><A HREF="${p}search/cust_event.html?invnum=!.
30 $cust_bill->invnum. '">( View invoice events )</A></FONT>';