X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fmisc%2Forder_pkg.html;h=864e8328c764d6d36c7ee11b5789b4acbe3ec698;hb=8a0204b4a129a3c26dcca18ba401b2de26d22d2b;hp=2c8335154753c122694a39496debe32ac51855d0;hpb=a661ced3f9f678a645780eaa0b183d2de5f100fa;p=freeside.git diff --git a/httemplate/misc/order_pkg.html b/httemplate/misc/order_pkg.html index 2c8335154..864e8328c 100644 --- a/httemplate/misc/order_pkg.html +++ b/httemplate/misc/order_pkg.html @@ -1,12 +1,23 @@ <% include('/elements/header-popup.html', 'Order new package' ) %> + + + + + + +% if ( $curuser->access_right('Discount customer package') ) { + <% include('/elements/tr-select-discount.html', + 'element_etc' => 'DISABLED', + 'colspan' => 7, + 'cgi' => $cgi, + ) + %> +% } + % if ( $conf->exists('pkg_referral') ) { <% include('/elements/tr-select-part_referral.html', 'curr_value' => scalar( $cgi->param('refnum') ), #get rid of empty_label first# || $cust_main->refnum, @@ -57,8 +101,10 @@ <%init> +my $curuser = $FS::CurrentUser::CurrentUser; + die "access denied" - unless $FS::CurrentUser::CurrentUser->access_right('Order customer package'); + unless $curuser->access_right('Order customer package'); my $conf = new FS::Conf; @@ -72,4 +118,8 @@ my $cust_main = qsearchs({ my $pkgpart = scalar($cgi->param('pkgpart')); +my $format = "%m/%d/%Y %T %z (%Z)"; #false laziness w/REAL_cust_pkg.cgi? +my $start_date = $cust_main->next_bill_date; +$start_date = $start_date ? time2str($format, $start_date) : ''; +