Smaller bug fixes [0000017]
authorJanusz Dobrowolski <janusz@frontaccounting.eu>
Mon, 14 Jul 2008 20:00:46 +0000 (20:00 +0000)
committerJanusz Dobrowolski <janusz@frontaccounting.eu>
Mon, 14 Jul 2008 20:00:46 +0000 (20:00 +0000)
CHANGELOG.txt
includes/ui/items_cart.inc
manufacturing/work_order_issue.php

index a4d44032b7e8ebc224b66f6d3f8ce45156792f01..527d5768ed12137b4d99fd5d8d8cc7c77dce49e8 100644 (file)
@@ -19,6 +19,13 @@ Legend:
 ! -> Note
 $ -> Affected files
 
+14-Jul-2008 Janusz Dobrowolski
+# Fixed bug [0000017] - error while checking qoh
+$ /includes/ui/items_cart.inc
+  /manufacturing/work_order_issue.php
+# Fixed ajax update
+$ /gl/manage/gl_accounts.php
+
 13-Jul-2008 Joe Hunt
 + Added GL Summary of Tax Report (rep709.php). Usable only if different Tax Accounts are used.
 $ /reporting/rep709.php
index fb2ac021694058ed01d676935ebb70fe15951122..a2d3e2d2e9a971494eee82baa76baa6d5de04872 100644 (file)
@@ -83,6 +83,7 @@ class items_cart
                        if ($item_ret != null)
                                return $line_no;
                }
+               return -1;
        }
 
        // ----------- GL item functions
index 31269cfc753b56e52ffa0446e48a567e1cae7f1e..5d518e56d7525323efbce8591da523488c9984b6 100644 (file)
@@ -85,7 +85,7 @@ function can_process()
        }
 
        $failed_item = $_SESSION['issue_items']->check_qoh($_POST['Location'], $_POST['date_'], !$_POST['IssueType']);
-       if ($failed_item != null
+       if ($failed_item >= 0
        {
        display_error( _("The issue cannot be processed because an entered item would cause a negative inventory balance :") .
                " " . $failed_item->stock_id . " - " .  $failed_item->item_description);