X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fmisc%2Fcatchall.cgi;h=240f34d0e017a85814adeac4ceb37d7db699ec4e;hp=79b72565b31dc114a72ddfe6e9d148b7b63f436b;hb=1fc8addc56f8daf12397da568eb1ac1b27fd3984;hpb=8a8c9386cbd3383b0134aae8e32b5995f8886fb2 diff --git a/httemplate/misc/catchall.cgi b/httemplate/misc/catchall.cgi index 79b72565b..240f34d0e 100755 --- a/httemplate/misc/catchall.cgi +++ b/httemplate/misc/catchall.cgi @@ -1,34 +1,43 @@ -<% -# -# $Id: catchall.cgi,v 1.1 2001-08-19 15:53:35 jeff Exp $ -# -# Usage: catchall.cgi {svcnum} -# http://server.name/path/catchall.cgi? {svcnum} -# -# $Log: catchall.cgi,v $ -# Revision 1.1 2001-08-19 15:53:35 jeff -# added user interface for svc_forward and vpopmail support -# -# - -use strict; -use vars qw( $conf $cgi $action $svcnum $svc_domain $pkgnum $svcpart - $part_svc $query %email $p1 $domain $catchall ); -use CGI; -use CGI::Carp qw(fatalsToBrowser); -use FS::UID qw(cgisuidsetup); -use FS::CGI qw(header popurl); -use FS::Record qw(qsearch qsearchs fields); -use FS::svc_acct; -use FS::svc_domain; -use FS::svc_forward; -use FS::Conf; - -$cgi = new CGI; -&cgisuidsetup($cgi); - -$conf = new FS::Conf; +<% include('/elements/header.html', 'Domain Catchall Edit') %> +<% include('/elements/error.html') %> + +
+ + +Service #<% $svcnum ? $svcnum : ' (NEW)' |h %> +

+ + + + + +% my $domain = $svc_domain->domain; +% my $catchall = $svc_domain->catchall; + + + +Mail to (anything)@<% $domain |h %> forwards to +

+ + + +
+ +<% include('/elements/footer.html') %> + +<%init> + +die "access denied" + unless $FS::CurrentUser::CurrentUser->access_right('Edit domain catchall'); + +my $conf = new FS::Conf; + +my($svc_domain, $svcnum, $pkgnum, $svcpart, $part_svc); if ( $cgi->param('error') ) { $svc_domain = new FS::svc_domain ( { map { $_, scalar($cgi->param($_)) } fields('svc_domain') @@ -61,6 +70,7 @@ if ( $cgi->param('error') ) { } } +my %email; if ($pkgnum) { #find all possible user svcnums (and emails) @@ -101,57 +111,8 @@ if ($pkgnum) { } # add an absence of a catchall -$email{0} = "(none)"; - -$p1 = popurl(1); -print $cgi->header( '-expires' => 'now' ), header("Domain Catchall Edit", ''); - -print qq!Error: !, $cgi->param('error'), - "" - if $cgi->param('error'); - -print qq!
!; - -#display - - #formatting - print "
";
-
-#svcnum
-print qq!!;
-print qq!Service #!, $svcnum ? $svcnum : " (NEW)", "";
-
-#pkgnum
-print qq!!;
- 
-#svcpart
-print qq!!;
-
-($domain,$catchall)=(
-  $svc_domain->domain,
-  $svc_domain->catchall,
-);
-
-print qq!!;
-
-#catchall
-print qq!\n\nMail to (anything)@$domain forwards to ";
-
-	#formatting
-	print "
\n"; - -print qq!
!; - -print < - - -END +my $p1 = popurl(1); -%> +