X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=fs_selfservice%2FFS-SelfService%2Fcgi%2Fprovision_list.html;h=818cd9f35da2558303c45216e6bf05040620dc20;hp=0f68dfe3cb8c8d2966b15e14be92870a809fc456;hb=d7eafc9c9aae2bf47ea19a56cc5bb1380c5874e4;hpb=a223750d9f7a4548319007807c3564ff3a8ebe40 diff --git a/fs_selfservice/FS-SelfService/cgi/provision_list.html b/fs_selfservice/FS-SelfService/cgi/provision_list.html index 0f68dfe3c..818cd9f35 100644 --- a/fs_selfservice/FS-SelfService/cgi/provision_list.html +++ b/fs_selfservice/FS-SelfService/cgi/provision_list.html @@ -9,16 +9,30 @@ function areyousure(href, message) { -<%= foreach my $pkg ( - grep { scalar(@{$_->{part_svc}}) - || scalar(@{$_->{cust_svc}}) - } @cust_pkg +<%= + +foreach my $pkg ( + grep { scalar(@{$_->{part_svc}}) + || scalar(@{$_->{cust_svc}}) + } @cust_pkg ) { + my $susp = $pkg->{'susp'} || ''; + warn $pkg->{'pkg'}. ' '.$susp."\n"; + my @pkg_actions = ( [ 'customer_change_pkg' => 'change' ] ); + push @pkg_actions, [ 'process_suspend_pkg' => 'suspend' ] + if $self_suspend_reason and !$susp; + my $bgcolor = $susp ? '"#ff9900"' : '"#8888ff"'; $OUT .= #'
'. - ''; + ''; my $col1 = "ffffff"; my $col2 = "dddddd"; @@ -75,7 +89,10 @@ function areyousure(href, message) { $OUT .= "$td COLSPAN=3 ALIGN=center>". qq!!. 'Setup '. $part_svc->{'svc'}. ' '. '('. $part_svc->{'num_avail'}. ' available)'. - ''; + '' + #self-service only supports these services so far + if grep { $part_svc->{'svcdb'} eq $_ } qw( svc_acct svc_external ); + $col = $col eq $col1 ? $col2 : $col1; }
'. - $pkg->{'pkg'}. - '
'. + $pkg->{'pkg'}. ($susp && ' (suspended)'). + ''; + foreach my $action (@pkg_actions) { + $OUT .= '(' . $action->[1] . ') '; + } + $OUT .= '