X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fbrowse%2Fpart_pkg.cgi;h=d0c14da4c6ac471426fe891d274326ba13c73ac7;hb=6b28d0bd4b422d0fff32b559d0785665b1c46b27;hp=b07386618ab1f70265252760485e6f4702cd887c;hpb=4427ad71b12bf27eac2a05d88141a82f9372d03f;p=freeside.git diff --git a/httemplate/browse/part_pkg.cgi b/httemplate/browse/part_pkg.cgi index b07386618..d0c14da4c 100755 --- a/httemplate/browse/part_pkg.cgi +++ b/httemplate/browse/part_pkg.cgi @@ -128,9 +128,16 @@ $select = " ( $count_cust_pkg AND ( cancel IS NULL OR cancel = 0 ) AND susp IS NOT NULL AND susp != 0 + AND setup IS NOT NULL AND setup != 0 ) AS num_suspended, ( $count_cust_pkg + AND ( cancel IS NULL OR cancel = 0 ) + AND susp IS NOT NULL AND susp != 0 + AND ( setup IS NULL OR setup = 0 ) + ) AS num_on_hold, + + ( $count_cust_pkg AND cancel IS NOT NULL AND cancel != 0 ) AS num_cancelled @@ -278,9 +285,8 @@ push @fields, sub { ), ], ( - map { my $amount = $_->amount - / (FS::part_pkg_usageprice->targets->{$_->target}{multiplier}||1); - my $label = FS::part_pkg_usageprice->targets->{$_->target}{label}; + map { my $amount = $_->amount / ($_->target_info->{multiplier} || 1); + my $label = $_->target_info->{label}; [ { data => "Plus $money_char". $_->price. ' '. ( $_->action eq 'increment' ? 'per' : 'for' ). @@ -383,6 +389,7 @@ if ( $acl_edit_global ) { #if ( $cgi->param('active') ) { push @header, 'Customer
packages'; my %col = ( + 'on hold' => '7E0079', #purple! 'not yet billed' => '009999', #teal? cyan? 'active' => '00CC00', 'suspended' => 'FF9900', @@ -398,10 +405,11 @@ if ( $acl_edit_global ) { my $label = $_; if ( $magic eq 'active' && $part_pkg->freq == 0 ) { $magic = 'inactive'; - #$label = 'one-time charge', - $label = 'charge', + #$label = 'one-time charge'; + $label = 'charge'; } $label= 'not yet billed' if $magic eq 'not_yet_billed'; + $label= 'on hold' if $magic eq 'on_hold'; [ { @@ -426,7 +434,7 @@ if ( $acl_edit_global ) { ), }, ], - } (qw( not_yet_billed active suspended cancelled )) + } (qw( on_hold not_yet_billed active suspended cancelled )) ), ($acl_config ? [ {},