From 33f1aac64b6f373538796ec616280b173f977f97 Mon Sep 17 00:00:00 2001 From: ivan Date: Sat, 26 Aug 2006 02:20:49 +0000 Subject: [PATCH] fix javascript for auto-setting application amount --- httemplate/edit/cust_bill_pay.cgi | 92 ++++++++++++++++++--------------------- 1 file changed, 42 insertions(+), 50 deletions(-) diff --git a/httemplate/edit/cust_bill_pay.cgi b/httemplate/edit/cust_bill_pay.cgi index 2035e4b64..d27d5c1da 100755 --- a/httemplate/edit/cust_bill_pay.cgi +++ b/httemplate/edit/cust_bill_pay.cgi @@ -1,39 +1,11 @@ -% -% -%my($paynum, $amount, $invnum); -%if ( $cgi->param('error') ) { -% $paynum = $cgi->param('paynum'); -% $amount = $cgi->param('amount'); -% $invnum = $cgi->param('invnum'); -%} else { -% my($query) = $cgi->keywords; -% $query =~ /^(\d+)$/; -% $paynum = $1; -% $amount = ''; -% $invnum = ''; -%} -% -%my $otaker = getotaker; -% -%my $p1 = popurl(1); -% -% <% header("Apply Payment", '') %> -% if ( $cgi->param('error') ) { +% if ( $cgi->param('error') ) { Error: <% $cgi->param('error') %>

% } -
-% -%my $cust_pay = qsearchs('cust_pay', { 'paynum' => $paynum } ); -%die "payment $paynum not found!" unless $cust_pay; -% -%my $unapplied = $cust_pay->unapplied; -% - Payment #<% $paynum %> @@ -43,28 +15,18 @@ Payment #<% $paynum %>
Amount: $<% $cust_pay->paid %>
Unapplied amount: $<% $unapplied %> -% -%my @cust_bill = grep $_->owed != 0, -% qsearch('cust_bill', { 'custnum' => $cust_pay->custnum } ); -% -% - -