Add missing location at the end.
authorMaxime Bourget <bmx007@gmail.com>
Sat, 1 Jun 2013 21:40:33 +0000 (22:40 +0100)
committerMaxime Bourget <bmx007@gmail.com>
Sat, 1 Jun 2013 21:40:33 +0000 (22:40 +0100)
haxe/ItemScheduler.hx

index bc763e9618ef4b1b0e46a69a924efeedcaf3b90e..75727a2091d62f179eaf39bf5ceebe9884e206b9 100644 (file)
@@ -111,6 +111,14 @@ class ItemScheduler {
                        formatOrder(order, left, location.delivery);
 
                }
+               // display the left locations
+                       while(0 > left && locationIter.hasNext()) {
+                               location = locationIter.next();
+                               var quantityForLocation : Int = location.quantityOnHand(stock_id, null);
+                               if(quantityForLocation == null || quantityForLocation == 0) continue;
+                               left += quantityForLocation;
+                               formatLocation(location, "Delivery", left);
+                       }
 
        }