From: Jonathan Prykop Date: Thu, 23 Apr 2015 00:46:28 +0000 (-0500) Subject: RT#34134: Processing a Credit Card Payment on Accounts X-Git-Url: http://git.freeside.biz/gitweb/?a=commitdiff_plain;h=11c37682117db820ace7f6bbd80c3d7efba5ee8f;p=freeside.git RT#34134: Processing a Credit Card Payment on Accounts --- diff --git a/FS/FS/Conf.pm b/FS/FS/Conf.pm index 6a661633f..4e2139b5b 100644 --- a/FS/FS/Conf.pm +++ b/FS/FS/Conf.pm @@ -2821,6 +2821,13 @@ and customer address. Include units.', 'type' => 'checkbox', }, + { + 'key' => 'manual_process-single_invoice_amount', + 'section' => 'billing', + 'description' => 'When entering manual credit card and ACH payments, amount will not autofill if the customer has more than one open invoice', + 'type' => 'checkbox', + }, + { 'key' => 'manual_process-pkgpart', 'section' => 'billing', diff --git a/httemplate/misc/payment.cgi b/httemplate/misc/payment.cgi index 90b03c7e8..b83ad7166 100644 --- a/httemplate/misc/payment.cgi +++ b/httemplate/misc/payment.cgi @@ -273,7 +273,9 @@ my @states = sort { $a cmp $b } keys %states; my $amount = ''; if ( $balance > 0 ) { - $amount = $balance; + $amount = $balance + unless $conf->exists('manual_process-single_invoice_amount') + && ($cust_main->open_cust_bill != 1); } my $payunique = "webui-payment-". time. "-$$-". rand() * 2**32;