Stable merged into unstable again (due to failure on binary file during previous...
[fa-stable.git] / sales / customer_invoice.php
index 9c9e171bddd11612f00a90a3add294bb0939bd6b..5bebcb7498ec398b67bc67d25fe315ee9ea3f385 100644 (file)
@@ -127,6 +127,8 @@ if ( (isset($_GET['DeliveryNumber']) && ($_GET['DeliveryNumber'] > 0) )
 
 } elseif (isset($_GET['ModifyInvoice']) && $_GET['ModifyInvoice'] > 0) {
 
+       check_is_closed(ST_SALESINVOICE, $_GET['ModifyInvoice']);
+
        if ( get_sales_parent_numbers(ST_SALESINVOICE, $_GET['ModifyInvoice']) == 0) { // 1.xx compatibility hack
                echo"<center><br><b>" . _("There are no delivery notes for this invoice.<br>
                Most likely this invoice was created in Front Accounting version prior to 2.0
@@ -264,7 +266,7 @@ function check_data()
        }
 
        if (!is_date_in_fiscalyear($_POST['InvoiceDate'])) {
-               display_error(_("The entered invoice date is not in fiscal year."));
+               display_error(_("The entered date is out of fiscal year or is closed for further data entry."));
                set_focus('InvoiceDate');
                return false;
        }