X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=sales%2Fcustomer_invoice.php;h=ca3df67fb3a1693b3bfee5dd8e030b3c9563481e;hb=13aa48ccc9265df336a1805d2e4709365f19c956;hp=ac2e75e5096942524f1cee56fe985376a7cb241b;hpb=b809585cf0244647799c9cecd52a380cb7ea32e0;p=fa-stable.git diff --git a/sales/customer_invoice.php b/sales/customer_invoice.php index ac2e75e5..ca3df67f 100644 --- a/sales/customer_invoice.php +++ b/sales/customer_invoice.php @@ -40,7 +40,6 @@ if (isset($_GET['AddedID'])) { $invoice_no = $_GET['AddedID']; $trans_type = 10; - print_hidden_script(10); display_notification(_("Selected deliveries has been processed"), true); @@ -57,7 +56,6 @@ if (isset($_GET['AddedID'])) { } elseif (isset($_GET['UpdatedID'])) { $invoice_no = $_GET['UpdatedID']; - print_hidden_script(10); display_notification_centered(sprintf(_('Sales Invoice # %d has been updated.'),$invoice_no)); @@ -142,6 +140,11 @@ if ( (isset($_GET['DeliveryNumber']) && ($_GET['DeliveryNumber'] > 0) ) if (isset($_POST['Update'])) { $Ajax->activate('Items'); } +if (isset($_POST['_InvoiceDate_changed'])) { + $_POST['due_date'] = get_invoice_duedate($_SESSION['Items']->customer_id, + $_POST['InvoiceDate']); + $Ajax->activate('due_date'); +} //----------------------------------------------------------------------------- function check_quantities() { @@ -333,7 +336,7 @@ if (!isset($_POST['InvoiceDate']) || !is_date($_POST['InvoiceDate'])) { } } -date_cells(_("Date"), 'InvoiceDate', '', $_POST['InvoiceDate'], 0, 0, 0, "class='tableheader2'"); +date_cells(_("Date"), 'InvoiceDate', '', $_POST['InvoiceDate'], 0, 0, 0, "class='tableheader2'", true); if (!isset($_POST['due_date']) || !is_date($_POST['due_date'])) { $_POST['due_date'] = get_invoice_duedate($_SESSION['Items']->customer_id, $_POST['InvoiceDate']);