Customer Payments: fixed allocatable transactions display on start of new customer...
authorJanusz Dobrowolski <janusz@frontaccounting.eu>
Fri, 15 Mar 2013 18:50:24 +0000 (19:50 +0100)
committerJanusz Dobrowolski <janusz@frontaccounting.eu>
Fri, 15 Mar 2013 18:54:27 +0000 (19:54 +0100)
sales/customer_payments.php

index b2eeb44ce90a04fd1328ac0ebfc49ec973e498ef..d437c37336af53f67212975ea69ec7e1ba7dd5fc 100644 (file)
@@ -76,8 +76,10 @@ if (list_updated('BranchID')) {
        $Ajax->activate('customer_id');
 }
 
-if (!isset($_POST['customer_id']))
-       $_POST['customer_id'] = get_global_customer(false);
+if (!isset($_POST['customer_id'])) {
+       $_SESSION['alloc']->person_id = $_POST['customer_id'] = get_global_customer(false);
+       $_SESSION['alloc']->read();
+}
 if (!isset($_POST['DateBanked'])) {
        $_POST['DateBanked'] = new_doc_date();
        if (!is_date_in_fiscalyear($_POST['DateBanked'])) {