X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fmisc%2Fprocess%2Flink.cgi;h=66f4ee11deed279815ad84ff8f9fcf7e3c2dae28;hb=718f65eee1c797ea90a315b5f03fae75c80a5112;hp=fd3d8bb1393ed2413f2fa4a0ee98990b951b6e7e;hpb=c8cccb4a92adceb943c635fe62dad0d034462ce0;p=freeside.git diff --git a/httemplate/misc/process/link.cgi b/httemplate/misc/process/link.cgi index fd3d8bb13..66f4ee11d 100755 --- a/httemplate/misc/process/link.cgi +++ b/httemplate/misc/process/link.cgi @@ -39,7 +39,7 @@ % % my $svc_x = $svc_x[0]; % -% eidiot("$link_field not found!") unless $svc_x; +% errorpage("$link_field not found!") unless $svc_x; % % $svcnum = $svc_x->svcnum; % @@ -52,11 +52,9 @@ %if ( $old->pkgnum && ! $conf->exists('legacy_link-steal') ) { % $error = "svcnum $svcnum already linked to package ". $old->pkgnum; %} else { -% $new = new FS::cust_svc ({ -% 'svcnum' => $svcnum, -% 'pkgnum' => $pkgnum, -% 'svcpart' => $svcpart, -% }); +% $new = new FS::cust_svc { $old->hash }; +% $new->pkgnum($pkgnum); +% $new->svcpart($svcpart); % % $error = $new->replace($old); %} @@ -71,7 +69,7 @@ % -% idiot($error); +% errorpage($error); %} % %