[freeside-commits] freeside/httemplate/misc link.cgi,1.11,1.12
Ivan,,,
ivan at wavetail.420.am
Fri Dec 29 00:51:35 PST 2006
Update of /home/cvs/cvsroot/freeside/httemplate/misc
In directory wavetail:/tmp/cvs-serv4384/httemplate/misc
Modified Files:
link.cgi
Log Message:
service refactor!
Index: link.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/misc/link.cgi,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- link.cgi 23 Aug 2006 22:25:38 -0000 1.11
+++ link.cgi 29 Dec 2006 08:51:33 -0000 1.12
@@ -1,6 +1,3 @@
-<!-- mason kludge -->
-%
-%
%my %link_field = (
% 'svc_acct' => 'username',
% 'svc_domain' => 'domain',
@@ -16,12 +13,10 @@
% },
%);
%
-%my($query) = $cgi->keywords;
-%my($pkgnum, $svcpart) = ('', '');
-%foreach $_ (split(/-/,$query)) { #get & untaint pkgnum & svcpart
-% $pkgnum=$1 if /^pkgnum(\d+)$/;
-% $svcpart=$1 if /^svcpart(\d+)$/;
-%}
+%$cgi->param('pkgnum') =~ /^(\d+)$/ or die 'unparsable pkgnum';
+%my $pkgnum = $1;
+%$cgi->param('svcpart') =~ /^(\d+)$/ or die 'unparsable svcpart';
+%my $svcpart = $1;
%
%my $part_svc = qsearchs('part_svc',{'svcpart'=>$svcpart});
%my $svc = $part_svc->getfield('svc');
@@ -29,8 +24,6 @@
%my $link_field = $link_field{$svcdb};
%my $link_field2 = $link_field2{$svcdb};
%
-%
-
<% include("/elements/header.html","Link to existing $svc") %>
<FORM ACTION="<% popurl(1) %>process/link.cgi" METHOD=POST>
More information about the freeside-commits
mailing list