2 % $cgi->param('error', $error);
3 <% $cgi->redirect(popurl(2). "svc_external.cgi?". $cgi->query_string ) %>
5 <% $cgi->redirect(popurl(3). "view/svc_external.cgi?$svcnum") %>
10 unless $FS::CurrentUser::CurrentUser->access_right('Provision customer service'); #something else more specific?
12 $cgi->param('svcnum') =~ /^(\d*)$/ or die "Illegal svcnum!";
15 my $old = qsearchs('svc_external',{'svcnum'=>$svcnum}) if $svcnum;
17 my $new = new FS::svc_external ( {
19 ($_, scalar($cgi->param($_)));
20 } ( fields('svc_external'), qw( pkgnum svcpart ) )
25 $error = $new->replace($old);
27 $error = $new->insert;
28 $svcnum = $new->getfield('svcnum');