From 5a6c2cf5ca5f1a80cad9310ec239a64dc8a280c1 Mon Sep 17 00:00:00 2001 From: Jonathan Prykop Date: Wed, 15 Jun 2016 22:19:13 -0500 Subject: RT#71298: Suspend Option for billing to continue --- httemplate/misc/process/cancel_pkg.html | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'httemplate/misc/process') diff --git a/httemplate/misc/process/cancel_pkg.html b/httemplate/misc/process/cancel_pkg.html index c7a43979d..6972a49bf 100755 --- a/httemplate/misc/process/cancel_pkg.html +++ b/httemplate/misc/process/cancel_pkg.html @@ -33,8 +33,10 @@ $method =~ /^(cancel|expire|suspend|adjourn|resume|uncancel)$/ $method = $1; my $past_method = $past{$method}; +my $curuser = $FS::CurrentUser::CurrentUser; + die "access denied" - unless $FS::CurrentUser::CurrentUser->access_right($right{$method}); + unless $curuser->access_right($right{$method}); #untaint pkgnum my $pkgnum = $cgi->param('pkgnum'); @@ -60,7 +62,8 @@ if ( $method eq 'suspend' ) { #or 'adjourn' $options = { map { $_ => scalar($cgi->param($_)) } qw( suspend_bill no_suspend_bill ) - }; + } + if $curuser->access_right('Customize billing during suspension'); } my $cust_pkg = qsearchs( 'cust_pkg', {'pkgnum'=>$pkgnum} ); -- cgit v1.2.1 From 9aa198dfc90054de34cf1af8f3238d004416ebc9 Mon Sep 17 00:00:00 2001 From: Jonathan Prykop Date: Tue, 21 Jun 2016 01:11:43 -0500 Subject: RT#17599: display cancelled services from history --- httemplate/misc/process/cancel_pkg.html | 3 +++ 1 file changed, 3 insertions(+) (limited to 'httemplate/misc/process') diff --git a/httemplate/misc/process/cancel_pkg.html b/httemplate/misc/process/cancel_pkg.html index 6972a49bf..eb3b2efe6 100755 --- a/httemplate/misc/process/cancel_pkg.html +++ b/httemplate/misc/process/cancel_pkg.html @@ -85,6 +85,8 @@ my $bill = my $svc_fatal = ( $cgi->param('svc_not_fatal') ne 'Y' ); +my $only_svcnum = ($method eq 'uncancel') ? [ $cgi->param('only_svcnum') ] : undef; + $error ||= $cust_pkg->$method( 'reason' => $reasonnum, 'date' => $date, 'resume_date' => $resume_date, @@ -92,6 +94,7 @@ $error ||= $cust_pkg->$method( 'reason' => $reasonnum, 'bill' => $bill, 'svc_fatal' => $svc_fatal, 'options' => $options, + 'only_svcnum' => $only_svcnum, ); if ($error) { -- cgit v1.2.1