X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=sales%2Fcustomer_payments.php;h=b81b609cbd5e243f3ce829481f5f8f63accc37e8;hb=a1c1f11e18aa72599123c36521a54a21a2c3d0bc;hp=34a862b1fc93e39c468bdfd73d46b8bdc69f7f60;hpb=6a12518d87e341c16dd2e2898f36e74320369d71;p=fa-stable.git diff --git a/sales/customer_payments.php b/sales/customer_payments.php index 34a862b1..b81b609c 100644 --- a/sales/customer_payments.php +++ b/sales/customer_payments.php @@ -251,11 +251,6 @@ if (isset($_POST['ref']) && $_SESSION['alloc']->trans_no == 0) // added by Joe t } $new = $_SESSION['alloc']->trans_no == 0; -if (list_updated('customer_id') || ($new && list_updated('bank_account'))) { - $_SESSION['alloc']->read(); - $_POST['memo_'] = $_POST['amount'] = $_POST['discount'] = ''; - $Ajax->activate('alloc_tbl'); -} //---------------------------------------------------------------------------------------------- if (isset($_POST['AddPaymentItem'])) { @@ -346,6 +341,12 @@ start_form(); hidden('customer_id', $_POST['customer_id']); } + if (list_updated('customer_id') || ($new && list_updated('bank_account'))) { + $_SESSION['alloc']->read(); + $_POST['memo_'] = $_POST['amount'] = $_POST['discount'] = ''; + $Ajax->activate('alloc_tbl'); + } + if (!isset($_POST['charge'])) // first page call { //Prepare allocation cart