summaryrefslogtreecommitdiff
path: root/htdocs/misc/process
diff options
context:
space:
mode:
authorivan <ivan>2001-08-13 01:09:02 +0000
committerivan <ivan>2001-08-13 01:09:02 +0000
commit1d758388ce3b17b8de1ae1d3a8ec39c1026baefc (patch)
tree86a620eb947174da33df01fc99e3e0f5ad7242f3 /htdocs/misc/process
parente6cf4af2b9d3ffefebe1a3e358f0674f566b56bc (diff)
removing
Diffstat (limited to 'htdocs/misc/process')
-rwxr-xr-xhtdocs/misc/process/delete-customer.cgi46
-rwxr-xr-xhtdocs/misc/process/link.cgi76
2 files changed, 0 insertions, 122 deletions
diff --git a/htdocs/misc/process/delete-customer.cgi b/htdocs/misc/process/delete-customer.cgi
deleted file mode 100755
index 0a939c559..000000000
--- a/htdocs/misc/process/delete-customer.cgi
+++ /dev/null
@@ -1,46 +0,0 @@
-#!/usr/bin/perl -Tw
-#
-# $Id: delete-customer.cgi,v 1.1 1999-04-15 16:44:36 ivan Exp $
-#
-# $Log: delete-customer.cgi,v $
-# Revision 1.1 1999-04-15 16:44:36 ivan
-# delete customers
-#
-
-use strict;
-use vars qw ( $cgi $conf $custnum $new_custnum $cust_main $error );
-use CGI;
-use CGI::Carp qw(fatalsToBrowser);
-use FS::UID qw(cgisuidsetup);
-use FS::Record qw(qsearchs);
-use FS::CGI qw(popurl);
-use FS::cust_main;
-
-$cgi = new CGI;
-cgisuidsetup($cgi);
-
-$conf = new FS::Conf;
-die "Customer deletions not enabled" unless $conf->exists('deletecustomers');
-
-$cgi->param('custnum') =~ /^(\d+)$/;
-$custnum = $1;
-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 = '';
-}
-$cust_main = qsearchs( 'cust_main', { 'custnum' => $custnum } )
- or die "Customer not found: $custnum";
-
-$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/htdocs/misc/process/link.cgi b/htdocs/misc/process/link.cgi
deleted file mode 100755
index 7d6bd506f..000000000
--- a/htdocs/misc/process/link.cgi
+++ /dev/null
@@ -1,76 +0,0 @@
-#!/usr/bin/perl -Tw
-#
-# $Id: link.cgi,v 1.6 2000-07-17 17:59:33 ivan Exp $
-#
-# ivan@voicenet.com 97-feb-5
-#
-# rewrite ivan@sisd.com 98-mar-18
-#
-# Changes to allow page to work at a relative position in server
-# bmccane@maxbaud.net 98-apr-3
-#
-# can also link on some other fields now (about time) ivan@sisd.com 98-jun-24
-#
-# $Log: link.cgi,v $
-# Revision 1.6 2000-07-17 17:59:33 ivan
-# oops
-#
-# Revision 1.5 1999/04/15 14:09:17 ivan
-# get rid of top-level my() variables
-#
-# Revision 1.4 1999/02/07 09:59:35 ivan
-# more mod_perl fixes, and bugfixes Peter Wemm sent via email
-#
-# Revision 1.3 1999/01/19 05:14:10 ivan
-# for mod_perl: no more top-level my() variables; use vars instead
-# also the last s/create/new/;
-#
-# Revision 1.2 1998/12/17 09:15:00 ivan
-# s/CGI::Request/CGI.pm/;
-#
-
-use strict;
-use vars qw ( $cgi $old $new $error $pkgnum $svcpart $svcnum );
-use CGI;
-use CGI::Carp qw(fatalsToBrowser);
-use FS::CGI qw(popurl idiot eidiot);
-use FS::UID qw(cgisuidsetup);
-use FS::cust_svc;
-use FS::Record qw(qsearchs);
-
-$cgi = new CGI;
-cgisuidsetup($cgi);
-
-$cgi->param('pkgnum') =~ /^(\d+)$/;
-$pkgnum = $1;
-$cgi->param('svcpart') =~ /^(\d+)$/;
-$svcpart = $1;
-$cgi->param('svcnum') =~ /^(\d*)$/;
-$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_acct)=qsearchs($svcdb,{$link_field => $cgi->param('link_value') });
- eidiot("$link_field not found!") unless $svc_acct;
- $svcnum=$svc_acct->svcnum;
-}
-
-$old = qsearchs('cust_svc',{'svcnum'=>$svcnum});
-die "svcnum not found!" unless $old;
-$new = new FS::cust_svc ({
- 'svcnum' => $svcnum,
- 'pkgnum' => $pkgnum,
- 'svcpart' => $svcpart,
-});
-
-$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 {
- idiot($error);
-}
-