From 7f1bc2a4b7282f8d8ff5fe403dee6e4e17753d44 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Fri, 10 May 2024 09:50:14 -0400 Subject: [PATCH] Update to workOrder loading. --- src/engine/db/handlers/dbWarehouseHandler.java | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/engine/db/handlers/dbWarehouseHandler.java b/src/engine/db/handlers/dbWarehouseHandler.java index a0888b3d..47d97e70 100644 --- a/src/engine/db/handlers/dbWarehouseHandler.java +++ b/src/engine/db/handlers/dbWarehouseHandler.java @@ -202,17 +202,13 @@ public class dbWarehouseHandler extends dbHandlerBase { Logger.error(e); } - // Remove the old workOrder records - - for (WorkOrder workOrder : submitList) - DbManager.WarehouseQueries.DELETE_WORKORDER(workOrder); - // Submit the new workOrders to the ForgeManager for (WorkOrder workOrder : submitList) { + DbManager.WarehouseQueries.DELETE_WORKORDER(workOrder); workOrder.workOrderID = ForgeManager.workOrderCounter.incrementAndGet(); - ForgeManager.vendorWorkOrderLookup.get(workOrder.vendor).add(workOrder); DbManager.WarehouseQueries.WRITE_WORKORDER(workOrder); + ForgeManager.vendorWorkOrderLookup.get(workOrder.vendor).add(workOrder); ForgeManager.forge.add(workOrder); }