diff options
author | cvs2git <cvs2git> | 1998-11-07 10:24:26 +0000 |
---|---|---|
committer | cvs2git <cvs2git> | 1998-11-07 10:24:26 +0000 |
commit | 48e7e549a27a76c357d50dd637e7ad5a29b9d43f (patch) | |
tree | e61ddacc0b1d6248ccfc61346f7f36fbb6723e56 /htdocs/edit/process/svc_acct_sm.cgi | |
parent | 47806ec845818ba69604e0452e7c7b25d62f0772 (diff) | |
parent | 4c9347994ca4e1aefdb622d9f51ac8687e6a177b (diff) |
This commit was manufactured by cvs2svn to create tag 'freeside_stable'.freeside_stable
Diffstat (limited to 'htdocs/edit/process/svc_acct_sm.cgi')
-rwxr-xr-x | htdocs/edit/process/svc_acct_sm.cgi | 80 |
1 files changed, 0 insertions, 80 deletions
diff --git a/htdocs/edit/process/svc_acct_sm.cgi b/htdocs/edit/process/svc_acct_sm.cgi deleted file mode 100755 index 9ad546bf4..000000000 --- a/htdocs/edit/process/svc_acct_sm.cgi +++ /dev/null @@ -1,80 +0,0 @@ -#!/usr/bin/perl -Tw -# -# process/svc_acct_sm.cgi: Add/edit a mail alias (process form) -# -# Usage: post form to: -# http://server.name/path/svc_acct_sm.cgi -# -# Note: Should br run setuid root as user nobody. -# -# lots of crufty stuff from svc_acct still in here, and modifications are (unelegantly) disabled. -# -# ivan@voicenet.com 97-jan-6 -# -# enabled modifications -# -# ivan@voicenet.com 97-may-7 -# -# fixed removal of cust_svc record on modifications! -# ivan@voicenet.com 97-jun-5 -# -# rewrite ivan@sisd.com 98-mar-15 -# -# Changes to allow page to work at a relative position in server -# bmccane@maxbaud.net 98-apr-3 - -use strict; -use CGI::Request; -use CGI::Carp qw(fatalsToBrowser); -use FS::UID qw(cgisuidsetup); -use FS::Record qw(qsearchs); -use FS::svc_acct_sm; - -my($req)=new CGI::Request; # create form object -cgisuidsetup($req->cgi); - -$req->param('svcnum') =~ /^(\d*)$/ or die "Illegal svcnum!"; -my($svcnum)=$1; - -my($old)=qsearchs('svc_acct_sm',{'svcnum'=>$svcnum}) if $svcnum; - -#unmunge domsvc and domuid -$req->param('domsvc',(split(/:/, $req->param('domsvc') ))[0] ); -$req->param('domuid',(split(/:/, $req->param('domuid') ))[0] ); - -my($new) = create FS::svc_acct_sm ( { - map { - ($_, scalar($req->param($_))); - } qw(svcnum pkgnum svcpart domuser domuid domsvc) -} ); - -my($error); -if ( $svcnum ) { - $error = $new->replace($old); -} else { - $error = $new->insert; - $svcnum = $new->getfield('svcnum'); -} - -unless ($error) { - $req->cgi->redirect("../../view/svc_acct_sm.cgi?$svcnum"); -} else { - CGI::Base::SendHeaders(); # one guess - print <<END; -<HTML> - <HEAD> - <TITLE>Error adding/editing mail alias</TITLE> - </HEAD> - <BODY> - <CENTER> - <H4>Error adding/editing mail alias</H4> - </CENTER> - Your update did not occur because of the following error: - <P><B>$error</B> - <P>Hit the <I>Back</I> button in your web browser, correct this mistake, and submit the form again. - </BODY> -</HTML> -END - -} - |