diff options
author | Mark Wells <mark@freeside.biz> | 2012-10-27 14:24:00 -0700 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2012-10-27 14:24:00 -0700 |
commit | eccc8de2366e2e004a37761b8da2b447ec861ecb (patch) | |
tree | bce8f9b106ae4fec53432600847352a48b0d14b5 /httemplate/edit/process | |
parent | 2c2da653a3d39945d8d2c244d102ccbee862053b (diff) |
ICS invoice spool format and email delivery, #17620
Diffstat (limited to 'httemplate/edit/process')
-rw-r--r-- | httemplate/edit/process/ftp_target.html | 12 | ||||
-rw-r--r-- | httemplate/edit/process/upload_target.html | 25 |
2 files changed, 25 insertions, 12 deletions
diff --git a/httemplate/edit/process/ftp_target.html b/httemplate/edit/process/ftp_target.html deleted file mode 100644 index 35f56c490..000000000 --- a/httemplate/edit/process/ftp_target.html +++ /dev/null @@ -1,12 +0,0 @@ -<& elements/process.html, - 'table' => 'ftp_target', - 'viewall_dir' => 'browse', - 'agent_null' => 1, -&> -<%init> -my $curuser = $FS::CurrentUser::CurrentUser; - -die "access denied" - unless $curuser->access_right('Configuration'); - -</%init> diff --git a/httemplate/edit/process/upload_target.html b/httemplate/edit/process/upload_target.html new file mode 100644 index 000000000..8755bed56 --- /dev/null +++ b/httemplate/edit/process/upload_target.html @@ -0,0 +1,25 @@ +<& elements/process.html, + 'table' => 'upload_target', + 'viewall_dir' => 'browse', + 'agent_null' => 1, + 'precheck_callback'=> \&precheck, +&> +<%init> +my $curuser = $FS::CurrentUser::CurrentUser; + +die "access denied" + unless $curuser->access_right('Configuration'); + +sub precheck { + my $cgi = shift; + my $protocol = $cgi->param('protocol'); + # promote whatever set of fields was selected to the "real" values + my $params = $cgi->Vars; + foreach ( keys %$params ) { + if ( $_ =~ /^${protocol}_(\w+)/ ) { + $cgi->param($1, $cgi->param($_)); + } + } +} + +</%init> |