From 43e6b2ea06434abead940939c9b04e00e3a72f32 Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Mon, 23 Apr 2012 20:27:17 -0700 Subject: manual control of quick payment application, #15861 --- httemplate/misc/xmlhttp-cust_bill-search.html | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 httemplate/misc/xmlhttp-cust_bill-search.html (limited to 'httemplate/misc/xmlhttp-cust_bill-search.html') diff --git a/httemplate/misc/xmlhttp-cust_bill-search.html b/httemplate/misc/xmlhttp-cust_bill-search.html new file mode 100644 index 000000000..46f15d1ab --- /dev/null +++ b/httemplate/misc/xmlhttp-cust_bill-search.html @@ -0,0 +1,18 @@ +<% encode_json(\@return) %> +<%init> + +my $curuser = $FS::CurrentUser::CurrentUser; +die 'access denied' unless $curuser->access_right('View invoices'); +my @return; +if ( $cgi->param('sub') eq 'custnum_search_open' ) { + my $custnum = $cgi->param('arg'); + #warn "searching invoices for $custnum\n"; + my $cust_main = FS::cust_main->by_key($custnum); + @return = map { + +{ $_->hash, + 'owed' => $_->owed } + } $cust_main->open_cust_bill + if $curuser->agentnums_href->{ $cust_main->agentnum }; +} + + -- cgit v1.2.1