-% if ( $bgcolor eq $bgcolor1 ) {
-% $bgcolor = $bgcolor2;
-% } else {
-% $bgcolor = $bgcolor1;
-% }
-
-
-<!--pkgnum: <% $cust_pkg->pkgnum %>-->
-<TR>
-
- <TD CLASS="grid" BGCOLOR="<% $bgcolor %>">
-
- <A NAME="cust_pkg<% $cust_pkg->pkgnum %>" ID="cust_pkg<% $cust_pkg->pkgnum %>"><% $cust_pkg->pkgnum %></A>:
- <% $part_pkg->pkg %> - <% $part_pkg->comment %>
- <BR>
-
- <FONT SIZE=-1>
-% unless ( $cust_pkg->get('cancel') ) {
-% my $br = 0;
-% if ( $curuser->access_right('Change customer package') ) { $br=1;
-
- ( <%pkg_change_link($cust_pkg)%> )
-% }
-% if ( $curuser->access_right('Edit customer package dates') ) { $br=1;
-
- ( <%pkg_dates_link($cust_pkg)%> )
-% }
-% if ( $curuser->access_right('Customize customer package') ) { $br=1;
-
- ( <%pkg_customize_link($cust_pkg,$cust_main->custnum)%> )
-% }
- <% $br ? '<BR>' : '' %>
-% }
-
-% if ( $cust_pkg->num_cust_event
-% && ( $curuser->access_right('Billing event reports')
-% || $curuser->access_right('View customer billing events')
-% )
-% ) {
- ( <%pkg_event_link($cust_pkg)%> )
-% }
-
- </FONT>
-
- </TD>
-
- <TD CLASS="inv" BGCOLOR="<% $bgcolor %>">
- <TABLE CLASS="inv" BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%">
-%
-% sub myfreq {
-% my $part_pkg = shift;
-% my $freq = $part_pkg->freq_pretty;
-% $freq =~ s/ / /g;
-% $freq;
-% }
-%
-% #this should use cust_pkg->status and cust_pkg->statuscolor eventually
-% #my $colspan = $conf->exists('cust_pkg-display_times') ? 8 : 4;
-% #my $width = $conf->exists('cust_pkg-display_times') ? '38%' : '56%';
-%
-% #false laziness w/edit/REAL_cust_pkg.cgi
-% my( $billed_or_prepaid, $last_bill_or_renewed, $next_bill_or_prepaid_until );
-% unless ( $part_pkg->is_prepaid ) {
-% $billed_or_prepaid = 'billed';
-% $last_bill_or_renewed = 'Last bill';
-% $next_bill_or_prepaid_until = 'Next bill';
-% } else {
-% $billed_or_prepaid = 'prepaid';
-% $last_bill_or_renewed = 'Renewed';
-% $next_bill_or_prepaid_until = 'Prepaid until';
-% }
-%
-%
-% if ( $cust_pkg->get('cancel') ) { #status: cancelled
-
- <% pkg_status_row($cust_pkg, 'Cancelled', 'cancel', 'color'=>'FF0000' ) %>
-
- <% pkg_status_row_colspan(
- ( $cust_pkg->last_reason ? $cust_pkg->last_reason->reason : '' ), '',
- 'align' => 'right', 'color' => 'ff0000', 'size' => '-2',
- )
- %>
-
-% unless ( $cust_pkg->get('setup') ) {
-
- <% pkg_status_row_colspan('Never billed') %>
-
-% } else {
-
- <% pkg_status_row( $cust_pkg, 'Setup', 'setup' ) %>
- <% pkg_status_row_changed( $cust_pkg ) %>
- <% pkg_status_row_if( $cust_pkg, $last_bill_or_renewed, 'last_bill' ) %>
- <% pkg_status_row_if( $cust_pkg, 'Suspended', 'susp' ) %>
-
-% }