diff options
author | ivan <ivan> | 2008-09-12 02:02:05 +0000 |
---|---|---|
committer | ivan <ivan> | 2008-09-12 02:02:05 +0000 |
commit | 569dbe716a5eb79f0f8e7216bb2baf27d40f60bf (patch) | |
tree | 1e3e78f2c5459fe948507ea88bc9b2e0b32c26c6 /httemplate | |
parent | bc65cfbb3b554ce94479c52c16bc6a27538b797a (diff) |
add billco respooling, not re-FTPing, RT#3971
Diffstat (limited to 'httemplate')
-rw-r--r-- | httemplate/misc/spool_invoices.cgi | 9 | ||||
-rwxr-xr-x | httemplate/search/cust_bill.html | 13 |
2 files changed, 21 insertions, 1 deletions
diff --git a/httemplate/misc/spool_invoices.cgi b/httemplate/misc/spool_invoices.cgi new file mode 100644 index 000000000..bfe24e6ea --- /dev/null +++ b/httemplate/misc/spool_invoices.cgi @@ -0,0 +1,9 @@ +<% $server->process %> +<%init> + +die "access denied" + unless $FS::CurrentUser::CurrentUser->access_right('Resend invoices'); + +my $server = new FS::UI::Web::JSRPC 'FS::cust_bill::process_respool', $cgi; + +</%init> diff --git a/httemplate/search/cust_bill.html b/httemplate/search/cust_bill.html index d22c74483..6f440db7e 100755 --- a/httemplate/search/cust_bill.html +++ b/httemplate/search/cust_bill.html @@ -188,7 +188,7 @@ my $html_init = join("\n", map { qq!<FORM NAME="${_}form">!, ( map qq!<INPUT TYPE="hidden" NAME="$_" VALUE="$search{$_}">!, keys %search ), qq!</FORM>! -} qw( print_ email_ fax_ ftp_ ) ). +} qw( print_ email_ fax_ ftp_ spool_ ) ). '<SCRIPT TYPE="text/javascript"> @@ -216,6 +216,12 @@ function confirm_ftp_process() { } ftp_process(); } +function confirm_spool_process() { + if ( ! confirm("Are you sure you want to re-spool these invoices?") ) { + return; + } + spool_process(); +} </SCRIPT>'; @@ -235,6 +241,11 @@ if ( $FS::CurrentUser::CurrentUser->access_right('Resend invoices') ) { push @$menubar, 'FTP these invoices' => "javascript:confirm_ftp_process()" if $conf->exists('cust_bill-ftpformat'); + + push @$menubar, 'Spool these invoices' => + "javascript:confirm_spool_process()" + if $conf->exists('cust_bill-spoolformat'); + } </%init> |