summaryrefslogtreecommitdiff
path: root/httemplate/misc/process
diff options
context:
space:
mode:
Diffstat (limited to 'httemplate/misc/process')
-rwxr-xr-xhttemplate/misc/process/catchall.cgi33
-rwxr-xr-xhttemplate/misc/process/delete-customer.cgi29
-rwxr-xr-xhttemplate/misc/process/link.cgi40
3 files changed, 0 insertions, 102 deletions
diff --git a/httemplate/misc/process/catchall.cgi b/httemplate/misc/process/catchall.cgi
deleted file mode 100755
index 44a63f9f8..000000000
--- a/httemplate/misc/process/catchall.cgi
+++ /dev/null
@@ -1,33 +0,0 @@
-<%
-
-$FS::svc_domain::whois_hack=1;
-
-$cgi->param('svcnum') =~ /^(\d*)$/ or die "Illegal svcnum!";
-my $svcnum =$1;
-
-my $old = qsearchs('svc_domain',{'svcnum'=>$svcnum}) if $svcnum;
-
-my $new = new FS::svc_domain ( {
- map {
- ($_, scalar($cgi->param($_)));
- } ( fields('svc_domain'), qw( pkgnum svcpart ) )
-} );
-
-$new->setfield('action' => 'M');
-
-my $error;
-if ( $svcnum ) {
- $error = $new->replace($old);
-} else {
- $error = $new->insert;
- $svcnum = $new->getfield('svcnum');
-}
-
-if ($error) {
- $cgi->param('error', $error);
- print $cgi->redirect(popurl(2). "catchall.cgi?". $cgi->query_string );
-} else {
- print $cgi->redirect(popurl(3). "view/svc_domain.cgi?$svcnum");
-}
-
-%>
diff --git a/httemplate/misc/process/delete-customer.cgi b/httemplate/misc/process/delete-customer.cgi
deleted file mode 100755
index 16bdbaea8..000000000
--- a/httemplate/misc/process/delete-customer.cgi
+++ /dev/null
@@ -1,29 +0,0 @@
-<%
-
-my $conf = new FS::Conf;
-die "Customer deletions not enabled" unless $conf->exists('deletecustomers');
-
-$cgi->param('custnum') =~ /^(\d+)$/;
-my $custnum = $1;
-my $new_custnum;
-if ( $cgi->param('new_custnum') ) {
- $cgi->param('new_custnum') =~ /^(\d+)$/
- or die "Illegal new customer number: ". $cgi->param('new_custnum');
- $new_custnum = $1;
-} else {
- $new_custnum = '';
-}
-my $cust_main = qsearchs( 'cust_main', { 'custnum' => $custnum } )
- or die "Customer not found: $custnum";
-
-my $error = $cust_main->delete($new_custnum);
-
-if ( $error ) {
- $cgi->param('error', $error);
- print $cgi->redirect(popurl(2). "delete-customer.cgi?". $cgi->query_string );
-} elsif ( $new_custnum ) {
- print $cgi->redirect(popurl(3). "view/cust_main.cgi?$new_custnum");
-} else {
- print $cgi->redirect(popurl(3));
-}
-%>
diff --git a/httemplate/misc/process/link.cgi b/httemplate/misc/process/link.cgi
deleted file mode 100755
index 4b220a867..000000000
--- a/httemplate/misc/process/link.cgi
+++ /dev/null
@@ -1,40 +0,0 @@
-<%
-
-$cgi->param('pkgnum') =~ /^(\d+)$/;
-my $pkgnum = $1;
-$cgi->param('svcpart') =~ /^(\d+)$/;
-my $svcpart = $1;
-$cgi->param('svcnum') =~ /^(\d*)$/;
-my $svcnum = $1;
-
-unless ( $svcnum ) {
- my($part_svc) = qsearchs('part_svc',{'svcpart'=>$svcpart});
- my($svcdb) = $part_svc->getfield('svcdb');
- $cgi->param('link_field') =~ /^(\w+)$/; my($link_field)=$1;
- my($svc_x)=qsearchs($svcdb,{$link_field => $cgi->param('link_value') });
- eidiot("$link_field not found!") unless $svc_x;
- $svcnum=$svc_x->svcnum;
-}
-
-my $old = qsearchs('cust_svc',{'svcnum'=>$svcnum});
-die "svcnum not found!" unless $old;
-#die "svcnum $svcnum already linked to package ". $old->pkgnum if $old->pkgnum;
-my $new = new FS::cust_svc ({
- 'svcnum' => $svcnum,
- 'pkgnum' => $pkgnum,
- 'svcpart' => $svcpart,
-});
-
-my $error = $new->replace($old);
-
-unless ($error) {
- #no errors, so let's view this customer.
- print $cgi->redirect(popurl(3). "view/cust_pkg.cgi?$pkgnum");
-} else {
-%>
-<!-- mason kludge -->
-<%
- idiot($error);
-}
-
-%>