summaryrefslogtreecommitdiff
path: root/httemplate/view/cust_pkg.cgi
blob: d8a0041eee80328f19b6d38b72688d207752e3d5 (plain)
1
2
3
4
5
6
7
8
9
10
11
<% $cgi->redirect($path) %>
<%init>
# since cust_pkgs can't be viewed directly, just throw a redirect
my ($pkgnum) = $cgi->keywords;
$pkgnum =~ /^\d+$/ or die "invalid pkgnum '$pkgnum'";
my $show = $FS::CurrentUser::CurrentUser->default_customer_view =~ /^(jumbo|packages)$/ ? '' : ';show=packages';

my $self = FS::cust_pkg->by_key($pkgnum) or die "pkgnum $pkgnum not found";
my $frag = 'cust_pkg'. $self->pkgnum;
my $path = $p.'view/cust_main.cgi?custnum='.$self->custnum.";$show#$frag";
</%init>