From 4ad099f874bf7c26b08660246017c1e5f38bf0ef Mon Sep 17 00:00:00 2001 From: pangshenghao Date: Fri, 7 Jul 2023 08:56:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=BB=BA=E6=8C=87=E4=BB=A4=E5=85=88?= =?UTF-8?q?=E5=88=9B=E5=BB=BA=E5=86=8D=E4=B8=8B=E5=8F=91=EF=BC=8C=E9=98=B2?= =?UTF-8?q?=E6=AD=A2=E6=9C=AA=E6=8F=92=E5=85=A5=E6=95=B0=E6=8D=AE=E5=BA=93?= =?UTF-8?q?NDC=E5=B7=B2=E6=9C=89=E5=8F=8D=E9=A6=88=E5=AF=BC=E8=87=B4?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E4=B8=8D=E5=AD=98=E5=9C=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../instruction/service/impl/InstructionServiceImpl.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/instruction/service/impl/InstructionServiceImpl.java b/acs/nladmin-system/src/main/java/org/nl/acs/instruction/service/impl/InstructionServiceImpl.java index 806cb6b..d8234f9 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/instruction/service/impl/InstructionServiceImpl.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/instruction/service/impl/InstructionServiceImpl.java @@ -339,7 +339,7 @@ public class InstructionServiceImpl implements InstructionService, ApplicationAu HongXiangConveyorDeviceDriver hongXiangConveyorDeviceDriver; StandardCoveyorControlWithScannerDeviceDriver standardCoveyorControlWithScannerDeviceDriver; - + WQLObject wo = WQLObject.getWQLObject("acs_instruction"); try { String start_device_code = dto.getStart_device_code(); String next_device_code = dto.getNext_device_code(); @@ -360,6 +360,9 @@ public class InstructionServiceImpl implements InstructionService, ApplicationAu if (ObjectUtil.isEmpty(route)) { throw new BadRequestException("未查询到相关路由!"); } + JSONObject json = (JSONObject) JSONObject.toJSON(dto); + wo.insert(json); + NDCAgvService ndcAgvService = SpringContextHolder.getBean(NDCAgvService.class); ndcAgvService.sendAgvInstToNDC(task.getAgv_system_type(), dto); @@ -370,10 +373,10 @@ public class InstructionServiceImpl implements InstructionService, ApplicationAu log.error(""); } - WQLObject wo = WQLObject.getWQLObject("acs_instruction"); + JSONObject json = (JSONObject) JSONObject.toJSON(dto); - wo.insert(json); + wo.update(json); instructions.add(dto); }