diff options
| author | Ivan Kohler <ivan@freeside.biz> | 2015-11-05 10:44:38 -0800 |
|---|---|---|
| committer | Ivan Kohler <ivan@freeside.biz> | 2015-11-05 10:44:38 -0800 |
| commit | 5da68ff1a7c638e30cbafbc9b0749f1e82b333df (patch) | |
| tree | ecbcbc0b06cb8af969987ad10e1d85ccf38e56da /httemplate/misc/void-cust_bill.cgi | |
| parent | 88ed72cdd96321a0eeaacc3107da413ab6e9dc98 (diff) | |
| parent | 052eb9b8d16c4e81c0b6c609674e9ab768cb817d (diff) | |
Merge branch 'master' of git.freeside.biz:/home/git/freeside
Diffstat (limited to 'httemplate/misc/void-cust_bill.cgi')
| -rwxr-xr-x | httemplate/misc/void-cust_bill.cgi | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/httemplate/misc/void-cust_bill.cgi b/httemplate/misc/void-cust_bill.cgi new file mode 100755 index 000000000..213cf9566 --- /dev/null +++ b/httemplate/misc/void-cust_bill.cgi @@ -0,0 +1,46 @@ +<& /elements/header-popup.html, mt('Void invoice') &> + +<% include('/elements/error.html') %> + +<% emt('Are you sure you want to void this invoice?') %> +<BR><BR> + +<% emt("Invoice #[_1] ([_2])",$cust_bill->display_invnum, $money_char. $cust_bill->owed) %> +<BR><BR> + +<FORM METHOD="POST" ACTION="process/void-cust_bill.html"> +<INPUT TYPE="hidden" NAME="invnum" VALUE="<% $invnum %>"> + +<% ntable("#cccccc", 2) %> +<& /elements/tr-select-reason.html, + 'field' => 'reasonnum', + 'reason_class' => 'X', + 'cgi' => $cgi +&> + +</TABLE> + +<BR> +<CENTER> +<BUTTON TYPE="submit">Yes, void invoice</BUTTON> \ +<BUTTON TYPE="button" onClick="parent.cClick();">No, do not void invoice</BUTTON> +</CENTER> + +</FORM> +</BODY> +</HTML> +<%init> + +die "access denied" + unless $FS::CurrentUser::CurrentUser->access_right('Void invoices'); + +my $conf = new FS::Conf; +my $money_char = $conf->config('money_char') || '$'; + +#untaint invnum +$cgi->param('invnum') =~ /^(\d+)$/ || die "Illegal invnum"; +my $invnum = $1; + +my $cust_bill = qsearchs('cust_bill',{'invnum'=>$invnum}); + +</%init> |
