4 <% $cgi->redirect(popurl(2). "view/cust_main.cgi?".$cust_pkg->getfield('custnum')) %>
9 unless $FS::CurrentUser::CurrentUser->access_right('Change customer package');
12 my ($query) = $cgi->keywords;
13 $query =~ /^(\d+)$/ || die "Illegal pkgnum";
16 my $cust_pkg = qsearchs('cust_pkg',{'pkgnum'=>$pkgnum});
17 my $change_to = FS::cust_pkg->by_key($cust_pkg->change_to_pkgnum);
19 my $err_or_pkg = $cust_pkg->change({ 'cust_pkg' => $change_to });
20 my $error = $err_or_pkg unless ref($err_or_pkg);