From fdb12b9760a4d9301cd7d0a17ae3842bb7d0db70 Mon Sep 17 00:00:00 2001 From: tuqiang <437016993@qq.com> Date: Fri, 19 Apr 2024 17:03:43 +0800 Subject: [PATCH 1/4] =?UTF-8?q?rev:=E6=89=8B=E6=8C=81=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/mapper/DeviceExtraMapper.java | 2 +- .../GreenFoilMachineButtonDriver.java | 42 ++++++++++--------- .../ItemProtocol.java | 5 +++ .../service/impl/TaskScreenServiceImpl.java | 3 ++ .../hand/service/impl/B2HandServiceImpl.java | 34 +++++++-------- .../nl/hand/service/impl/HandServiceImpl.java | 12 ++---- .../nladmin-ui/src/views/screen/bigScreen.vue | 10 +---- 7 files changed, 50 insertions(+), 58 deletions(-) diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device/service/mapper/DeviceExtraMapper.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device/service/mapper/DeviceExtraMapper.java index e7753a8fb..602fad8fe 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device/service/mapper/DeviceExtraMapper.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device/service/mapper/DeviceExtraMapper.java @@ -57,6 +57,6 @@ public interface DeviceExtraMapper extends CommonMapper { * @param extra_code * @return */ - @Select("select * from lzhl_two_acs.acs_device_extra where device_id=#{device_id} and extra_code=#{extra_code} order by create_time desc") + @Select("select * from acs_device_extra where device_id=#{device_id} and extra_code=#{extra_code} order by create_time desc") DeviceExtra findByDeviceId(@Param("device_id") String device_id, @Param("extra_code") String extra_code); } diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/GreenFoilMachineButtonDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/GreenFoilMachineButtonDriver.java index 8239b524c..7e8081ce0 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/GreenFoilMachineButtonDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/GreenFoilMachineButtonDriver.java @@ -88,6 +88,11 @@ public class GreenFoilMachineButtonDriver extends AbstractOpcDeviceDriver implem public int lastMove = 0; public int lastAction = 0; public int lastError = 0; + int to_command = 0; + int last_to_command = 0; + + int to_error = 0; + int last_to_error = 0; Boolean isonline = true; @@ -117,6 +122,8 @@ public class GreenFoilMachineButtonDriver extends AbstractOpcDeviceDriver implem action = this.itemProtocol.getItem_action(); error = this.itemProtocol.getItem_error(); iserror = this.itemProtocol.isError; + to_command = this.itemProtocol.getItem_to_command(); + to_error = this.itemProtocol.getItem_error(); if (mode != lastMode) { requireSucess = false; @@ -134,7 +141,7 @@ public class GreenFoilMachineButtonDriver extends AbstractOpcDeviceDriver implem } else if (error != 0) { this.setIserror(true); message = "universal_message3"; - }else { + } else { this.setIsonline(true); this.setIserror(false); message = ""; @@ -175,11 +182,12 @@ public class GreenFoilMachineButtonDriver extends AbstractOpcDeviceDriver implem } - lastMode = mode; lastMove = move; lastAction = action; lastError = error; + last_to_error = to_error; + last_to_command = to_command; } @@ -203,20 +211,20 @@ public class GreenFoilMachineButtonDriver extends AbstractOpcDeviceDriver implem if (ObjectUtil.isEmpty(response)) { message = "two_message18"; } else { - if (response.getCode()== CommonFinalParam.STATUS_OPEN) { - if (mode==4){ - this.writing("to_command","4"); - }else if (mode==5){ - this.writing("to_command","5"); - }else if (mode==9){ - this.writing("to_command","9"); + if (response.getCode() == CommonFinalParam.STATUS_OPEN) { + if (mode == 4) { + this.writing("to_command", "4"); + } else if (mode == 5) { + this.writing("to_command", "5"); + } else if (mode == 9) { + this.writing("to_command", "9"); } message = "two_message19"; requireSucess = true; } else { requireSucess = false; message = "two_message20" + response.getMessage(); - this.writing("to_command","99"); + this.writing("to_command", "99"); } } } @@ -224,8 +232,6 @@ public class GreenFoilMachineButtonDriver extends AbstractOpcDeviceDriver implem } - - public void writing(String param, String value) { String to_param = this.getDevice().getOpc_server_code() + "." + this.getDevice().getOpc_plc_code() + "." + this.getDevice().getDevice_code() @@ -277,14 +283,12 @@ public class GreenFoilMachineButtonDriver extends AbstractOpcDeviceDriver implem requireSucess = "1"; } jo.put("requireSucess", requireSucess); - if (this.getAction() == 1) { - action = "取货中"; + if (this.getAction() == 0) { + action = "不允许取放"; + } else if (this.getAction() == 1) { + action = "允许取放"; } else if (this.getAction() == 2) { - action = "取货完成"; - } else if (this.getAction() == 3) { - action = "放货中"; - } else if (this.getAction() == 4) { - action = "放货完成"; + action = "允许离开"; } jo.put("device_name", this.getDevice().getDevice_name()); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/ItemProtocol.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/ItemProtocol.java index f39c57e1b..66352ac60 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/ItemProtocol.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/green_foil_machine_button/ItemProtocol.java @@ -20,6 +20,7 @@ public class ItemProtocol { public static String item_to_command = "to_command"; + public static String item_to_error = "to_error"; private GreenFoilMachineButtonDriver driver; @@ -42,6 +43,9 @@ public class ItemProtocol { }; public int getItem_error(){ return this.getOpcIntegerValue(item_error); + } + public int getItem_to_command(){ + return this.getOpcIntegerValue(item_to_error); } ; Boolean isonline; @@ -89,6 +93,7 @@ public class ItemProtocol { public static List getWriteableItemDtos() { ArrayList list = new ArrayList(); list.add(new ItemDto(item_to_command, "下发命令", "DB6.W0")); + list.add(new ItemDto(item_to_error, "下发故障代码", "DB6.W1")); return list; } diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/taskscreen/service/impl/TaskScreenServiceImpl.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/taskscreen/service/impl/TaskScreenServiceImpl.java index c9e3ccd7d..5df32fbfb 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/taskscreen/service/impl/TaskScreenServiceImpl.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/taskscreen/service/impl/TaskScreenServiceImpl.java @@ -81,6 +81,9 @@ public class TaskScreenServiceImpl extends CommonServiceImpl extraDeviceCodes = getExtraDeviceCodes(extraValue); if (CollUtil.isEmpty(extraDeviceCodes) || extraDeviceCodes.size() < 0) { diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/B2HandServiceImpl.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/B2HandServiceImpl.java index 2b97438f6..9f8f92ae1 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/B2HandServiceImpl.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/B2HandServiceImpl.java @@ -54,19 +54,13 @@ public class B2HandServiceImpl implements B2HandService { String task_type = dto.getTask_type(); if (StrUtil.isEmpty(start_device_code)) { - JSONObject json = new JSONObject(); - json.put("message", "起点1不能为空"); - errArr.add(json); + throw new BadRequestException("起点1不能为空"); } if (StrUtil.isEmpty(next_device_code)) { - JSONObject json = new JSONObject(); - json.put("message", "终点1不能为空"); - errArr.add(json); + throw new BadRequestException("终点1不能为空"); } if (StrUtil.isEmpty(task_type)) { - JSONObject json = new JSONObject(); - json.put("message", "任务类型不能为空"); - errArr.add(json); + throw new BadRequestException("任务类型不能为空"); } JSONObject jo = new JSONObject(); @@ -85,11 +79,8 @@ public class B2HandServiceImpl implements B2HandService { jo.put("next_device_code", next_device_code); jo.put("start_point_code", start_device_code); jo.put("next_point_code", next_device_code); - jo.put("start_device_code2", start_device_code2); - jo.put("next_device_code2", next_device_code2); - jo.put("start_point_code2", start_device_code2); - jo.put("next_point_code2", next_device_code2); jo.put("task_type", task_type); + jo.put("route_plan_code","normal"); jo.put("agv_system_type", "2"); jo.put("priority", "1"); @@ -101,6 +92,7 @@ public class B2HandServiceImpl implements B2HandService { JSONObject json = new JSONObject(); json.put("message", e.getMessage()); errArr.add(json); + throw new RuntimeException(e.getMessage()); } JSONArray data = new JSONArray(); JSONObject resultJson = new JSONObject(); @@ -119,7 +111,7 @@ public class B2HandServiceImpl implements B2HandService { JSONArray data = new JSONArray(); //查询所有生箔区的设备 List list = deviceService.lambdaQuery() - .eq(Device::getRegion, "2") + .eq(Device::getRegion, "1") .list(); if (CollectionUtil.isEmpty(list)) { throw new BadRequestException("未查到该区域的设备!"); @@ -158,15 +150,12 @@ public class B2HandServiceImpl implements B2HandService { String device_code = dto.getDevice_code(); String option = dto.getOption(); if (StrUtil.isEmpty(device_code)) { - JSONObject json = new JSONObject(); - json.put("message", "设备号不能为空"); - errArr.add(json); + throw new BadRequestException("设备号不能为空"); } if (StrUtil.isEmpty(option)) { - JSONObject json = new JSONObject(); - json.put("message", "操作不能为空"); - errArr.add(json); + throw new BadRequestException("操作不能为空"); } + //满轴位允许进入,空轴位允许离开 if (device_code.contains("M")&&(!"1".equals(option))){ throw new BadRequestException("该设备为满轴位,不能进行该操作"); } @@ -175,6 +164,11 @@ public class B2HandServiceImpl implements B2HandService { } StandardOrdinarySiteDeviceDriver standardOrdinarySiteDeviceDriver; Device device = deviceAppService.findDeviceByCode(device_code); + if (ObjectUtil.isEmpty(device)){ + JSONObject json = new JSONObject(); + json.put("message", "设备不存在!"); + errArr.add(json); + } standardOrdinarySiteDeviceDriver = (StandardOrdinarySiteDeviceDriver) device.getDeviceDriver(); standardOrdinarySiteDeviceDriver.setOption(Integer.parseInt(option)); JSONArray data = new JSONArray(); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/HandServiceImpl.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/HandServiceImpl.java index 614f900ac..2ab183114 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/HandServiceImpl.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/hand/service/impl/HandServiceImpl.java @@ -115,19 +115,13 @@ public class HandServiceImpl implements HandService { String task_type = dto.getTask_type(); if (StrUtil.isEmpty(start_device_code)) { - JSONObject json = new JSONObject(); - json.put("message", "起点不能为空"); - errArr.add(json); + throw new BadRequestException("起点不能为空"); } if (StrUtil.isEmpty(next_device_code)) { - JSONObject json = new JSONObject(); - json.put("message", "终点不能为空"); - errArr.add(json); + throw new BadRequestException("终点不能为空"); } if (StrUtil.isEmpty(task_type)) { - JSONObject json = new JSONObject(); - json.put("message", "任务类型不能为空"); - errArr.add(json); + throw new BadRequestException("任务类型不能为空"); } String start_device_code2 = ""; diff --git a/acs2/nladmin-ui/src/views/screen/bigScreen.vue b/acs2/nladmin-ui/src/views/screen/bigScreen.vue index 065349377..02881081b 100644 --- a/acs2/nladmin-ui/src/views/screen/bigScreen.vue +++ b/acs2/nladmin-ui/src/views/screen/bigScreen.vue @@ -153,7 +153,7 @@ export default { const timer = setInterval(() => { this.settime()// 你所加载数据的方法 this.getMessage() - }, 10000) + }, 1000) // 销毁定时器 this.$once('hook:beforeDestroy', () => { clearInterval(timer) @@ -175,14 +175,6 @@ export default { methods: { changeDevice(val) { this.device = val - deviceCrud.getLedMessage(this.device).then(data => { - this.form = data - }) - // todo: 定时器 - this.timer = setInterval(() => { // 定时刷新设备的状态信息 - console.log('定时器启动') - this.initStatus() - }, 10000) }, getMessage() { deviceCrud.getLedMessage(this.device).then(data => { From 9b3980a71e53c756358985ae0daa8bf08d64eb7e Mon Sep 17 00:00:00 2001 From: yanps Date: Sat, 20 Apr 2024 09:41:39 +0800 Subject: [PATCH 2/4] =?UTF-8?q?opt:=20=E5=A0=86=E5=9E=9B=E6=9C=BA=E8=AF=BB?= =?UTF-8?q?=E5=8F=96=E4=B8=8B=E5=8F=91=E4=BF=A1=E5=8F=B7=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../device_driver/stacker/standard_stacker/ItemProtocol.java | 2 +- .../stacker/standard_stacker/StandardStackerDeviceDriver.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/ItemProtocol.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/ItemProtocol.java index 7b40ef7ee..6ff248ff1 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/ItemProtocol.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/ItemProtocol.java @@ -39,7 +39,7 @@ public class ItemProtocol { /** * y轴报警(载货台) */ - public static String item_error = "error"; + public static String item_error = "Error"; /** * 行走排号 diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java index 9b580bd11..4d4410394 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java @@ -493,7 +493,7 @@ public class StandardStackerDeviceDriver extends AbstractOpcDeviceDriver impleme message = "universal_releasing_completed"; Map map = new HashMap<>(); map.put("code", "to_command"); - map.put("value", 5); + map.put("value", 11); list.add(map); Instruction inst = checkInst(); try { From ad066d69888da7a6001e43496fd1ea0e244136e4 Mon Sep 17 00:00:00 2001 From: liuxy Date: Mon, 22 Apr 2024 13:33:57 +0800 Subject: [PATCH 3/4] =?UTF-8?q?rev=EF=BC=9A1.=E6=8F=90=E7=A4=BA=E4=BC=98?= =?UTF-8?q?=E5=8C=962.=E6=8A=A5=E9=94=99=EF=BC=9Axx=E8=B4=A7=E4=BD=8D?= =?UTF-8?q?=E9=98=BB=E6=8C=A1=20-=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../instor/service/impl/HandMoveStorServiceImpl.java | 11 ++++++----- .../outbill/service/impl/CheckOutBillServiceImpl.java | 8 ++++---- .../nl/wms/st/outbill/wql/QST_IVT_CHECKOUTBILL.wql | 2 +- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/lms/nladmin-system/src/main/java/org/nl/wms/st/instor/service/impl/HandMoveStorServiceImpl.java b/lms/nladmin-system/src/main/java/org/nl/wms/st/instor/service/impl/HandMoveStorServiceImpl.java index 39d0373ae..5f4fe2fd1 100644 --- a/lms/nladmin-system/src/main/java/org/nl/wms/st/instor/service/impl/HandMoveStorServiceImpl.java +++ b/lms/nladmin-system/src/main/java/org/nl/wms/st/instor/service/impl/HandMoveStorServiceImpl.java @@ -1401,7 +1401,8 @@ public class HandMoveStorServiceImpl implements HandMoveStorService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); + } throw new BadRequestException("仓位:" + error + "被锁定且未下发任务,无法生成任务!"); @@ -1428,7 +1429,7 @@ public class HandMoveStorServiceImpl implements HandMoveStorService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定且未下发任务,无法生成任务!"); @@ -1454,7 +1455,7 @@ public class HandMoveStorServiceImpl implements HandMoveStorService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定且未下发任务,无法生成任务!"); @@ -1484,7 +1485,7 @@ public class HandMoveStorServiceImpl implements HandMoveStorService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定且未下发任务,无法生成任务!"); @@ -1515,7 +1516,7 @@ public class HandMoveStorServiceImpl implements HandMoveStorService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定且未下发任务,无法生成任务!"); diff --git a/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/service/impl/CheckOutBillServiceImpl.java b/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/service/impl/CheckOutBillServiceImpl.java index c6bcf40fe..272599cea 100644 --- a/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/service/impl/CheckOutBillServiceImpl.java +++ b/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/service/impl/CheckOutBillServiceImpl.java @@ -2776,7 +2776,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定请等待下发任务并等待任务完成"); @@ -2810,7 +2810,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定请等待下发任务并等待任务完成"); @@ -3229,7 +3229,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定请等待下发任务并等待任务完成"); @@ -3260,7 +3260,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService { for (int k = 0; k < numArr.size(); k++) { JSONObject json = numArr.getJSONObject(k); - error += json.getString("struct_code") + ","; + error += json.getString("struct_code") + ", 锁定单据号:"+json.getString("inv_code"); } throw new BadRequestException("仓位:" + error + "被锁定请等待下发任务并等待任务完成!"); diff --git a/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/wql/QST_IVT_CHECKOUTBILL.wql b/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/wql/QST_IVT_CHECKOUTBILL.wql index 7a3c9cb0f..def387727 100644 --- a/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/wql/QST_IVT_CHECKOUTBILL.wql +++ b/lms/nladmin-system/src/main/java/org/nl/wms/st/outbill/wql/QST_IVT_CHECKOUTBILL.wql @@ -1196,7 +1196,7 @@ AND task_status IN ('07') AND is_delete = '0' AND task_type = '010503' - AND DATEDIFF( NOW(), LEFT(update_time,10) ) <= 2 + AND TIMESTAMPDIFF(HOUR,update_time,NOW()) <= 3 ENDSELECT ENDQUERY From c48f46040a1769007f8174518bed885c70681d12 Mon Sep 17 00:00:00 2001 From: yanps Date: Mon, 22 Apr 2024 13:35:23 +0800 Subject: [PATCH 4/4] =?UTF-8?q?opt:=20=E8=A1=8C=E6=9E=B6=E8=81=94=E8=B0=83?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../agv/ndctwo/AgvNdcTwoDeviceDriver.java | 2 +- .../BeltConveyorDeviceDriver.java | 6 + ...ConveyorWithScannerWeightDeviceDriver.java | 2 +- .../StandardStackerDeviceDriver.java | 23 ++ .../HongXiangConveyorDeviceDriver.java | 31 +++ .../OvenGantryManipulatorDeviceDriver.java | 223 +++++++++--------- .../service/quartz/config/JobRunner.java | 2 +- .../src/views/acs/monitor/device/index2.vue | 18 ++ 8 files changed, 190 insertions(+), 117 deletions(-) diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/agv/ndctwo/AgvNdcTwoDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/agv/ndctwo/AgvNdcTwoDeviceDriver.java index e9af097f9..47afce62e 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/agv/ndctwo/AgvNdcTwoDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/agv/ndctwo/AgvNdcTwoDeviceDriver.java @@ -421,7 +421,7 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic } catch (Exception e) { e.printStackTrace(); } - if ((standardInspectSiteDeviceDriver.getMove() == 1 && standardInspectSiteDeviceDriver.getAction() == 1 && standardInspectSiteDeviceDriver.getError() == 0)) { + if ((standardInspectSiteDeviceDriver.getMove() != 1 && standardInspectSiteDeviceDriver.getAction() == 1 && standardInspectSiteDeviceDriver.getError() == 0)) { data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0); } else { message = "设备号:" + device_code + "光电信号:" + standardInspectSiteDeviceDriver.getMove() + ",动作信号:" + standardInspectSiteDeviceDriver.getAction() + "报警信号:" + standardInspectSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件"; diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/belt_conveyor/BeltConveyorDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/belt_conveyor/BeltConveyorDeviceDriver.java index 6d3411345..aaf6188cb 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/belt_conveyor/BeltConveyorDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/belt_conveyor/BeltConveyorDeviceDriver.java @@ -748,6 +748,12 @@ public class BeltConveyorDeviceDriver extends AbstractOpcDeviceDriver implements if (this.move == 1) { move = "有货"; } + String container_type = ""; + if(this.container_type == 1){ + container_type = "小托盘"; + }else if (this.container_type == 2){ + container_type = "大托盘"; + } jo.put("move", move); jo.put("task", task); jo.put("type", container_type); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/scanner_weight_conveyor/ConveyorWithScannerWeightDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/scanner_weight_conveyor/ConveyorWithScannerWeightDeviceDriver.java index 008296434..514f26eaf 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/scanner_weight_conveyor/ConveyorWithScannerWeightDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/scanner_weight_conveyor/ConveyorWithScannerWeightDeviceDriver.java @@ -513,7 +513,7 @@ public class ConveyorWithScannerWeightDeviceDriver extends AbstractOpcDeviceDriv log.error("指令创建失败!", e.getMessage()); return false; } - Device nextdevice = deviceAppservice.findDeviceByCode(taskdto.getNext_device_code()); + Device nextdevice = deviceAppservice.findDeviceByCode(instdto.getNext_device_code()); //创建指令后修改任务状态 taskdto.setTask_status(TaskStatusEnum.BUSY.getIndex()); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java index 4d4410394..bc656c560 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/stacker/standard_stacker/StandardStackerDeviceDriver.java @@ -979,8 +979,31 @@ public class StandardStackerDeviceDriver extends AbstractOpcDeviceDriver impleme if (this.requireSucess) { requireSucess = "1"; } + String command = ""; + if(this.command == 0){ + command = "待机"; + }else if(this.command == 1){ + command = "取货中"; + }else if(this.command == 2){ + command = "取货完成"; + }else if(this.command == 3){ + command = "放货中"; + }else if(this.command == 4){ + command = "请求卸货(申请卸货)"; + }else if(this.command == 5){ + command = "放货完成"; + }else if(this.command == 6){ + command = "取货准备(回库台)"; + }else if(this.command == 7){ + command = "召回"; + }else if(this.command == 8){ + command = "急停"; + }else if(this.command == 9){ + command = "未知"; + } jo.put("mode", mode); jo.put("move", move); + jo.put("command", command); jo.put("action", action); jo.put("task", task); jo.put("error", this.getError()); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/hongxiang_device/HongXiangConveyorDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/hongxiang_device/HongXiangConveyorDeviceDriver.java index a9a469c36..1a560176f 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/hongxiang_device/HongXiangConveyorDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/hongxiang_device/HongXiangConveyorDeviceDriver.java @@ -282,6 +282,37 @@ public class HongXiangConveyorDeviceDriver extends AbstractOpcDeviceDriver imple } } + + public void writing(List list) { + Map itemMap = new HashMap(); + for (int i = 0; i < list.size(); i++) { + Object ob = list.get(i); + JSONObject json = (JSONObject) JSONObject.toJSON(ob); + if (!StrUtil.isEmpty(json.getString("value"))) { + String to_param = this.getDevice().getOpc_server_code() + "." + this.getDevice().getOpc_plc_code() + "." + this.getDevice().getDevice_code() + + "." + json.getString("code"); + itemMap.put(to_param, json.getString("value")); + } + } + LuceneLogDto logDto = LuceneLogDto.builder() + .device_code(device_code) + .content("下发电气信号:" + itemMap) + .build(); + luceneExecuteLogService.deviceExecuteLog(logDto); + logServer.deviceExecuteLog(device_code, "", "", "下发电气信号:" + itemMap); + try { + this.checkcontrol(itemMap); + } catch (Exception e) { + e.printStackTrace(); + try { + this.checkcontrol(itemMap); + } catch (Exception e1) { + e1.printStackTrace(); + } + } + + } + //将扩展表中的字符串数据转换成集合 @Override public List getExtraDeviceCodes(String extraName) { diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java index f81c4d666..6cd660ac0 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java @@ -128,6 +128,8 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i private int instruction_require_time_out = 3000; //行架机械手申请任务成功标识 boolean requireSucess = false; + //行架机械手申请动作成功标识 + boolean requireActionSucess = false; private int instruction_finished_time_out; @@ -179,12 +181,16 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i y_position = this.itemProtocol.getY_position(); iserror = this.itemProtocol.device_status; - if(mode != last_mode){ + if (mode != last_mode) { requireSucess = false; } + if (action != last_action) { + requireActionSucess = false; + } - - update_instruction_status(); + if (!requireActionSucess) { + update_instruction_status(); + } } catch (Exception var17) { var17.printStackTrace(); @@ -219,7 +225,7 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i } else { if (mode == 2) { //if (!requireSucess) { - String remark = "";; + String remark = ""; if (mode != 2) { remark = remark + "工作模式(mode)不是待机状态,"; } @@ -293,7 +299,9 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i if (ObjectUtil.isEmpty(putDeviceCodeList)) { putDeviceCodeList = this.getExtraDeviceCodes("put_device_code"); } - + if(CollUtil.isEmpty(getDeviceCodeList) || getDeviceCodeList.size() == 0){ + notCreateInstMessage = "未设置取货点"; + } TaskDto task = null; for (int i = 0; i < getDeviceCodeList.size(); i++) { String startDeviceCode = getDeviceCodeList.get(i); @@ -431,7 +439,6 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i hongXiangConveyorDeviceDriver = (HongXiangConveyorDeviceDriver) nextdevice.getDeviceDriver(); hongXiangConveyorDeviceDriver.writing("to_open_door", "1"); } - this.setNow_steps_type(2); this.setRequireSucess(true); return true; } else { @@ -593,7 +600,7 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i } String start_addr = startDevice.getExtraValue().get("address").toString(); String next_addr = nextDevice.getExtraValue().get("address").toString(); - if(ObjectUtil.isEmpty(start_addr) || ObjectUtil.isEmpty(next_addr)){ + if (ObjectUtil.isEmpty(start_addr) || ObjectUtil.isEmpty(next_addr)) { throw new BadRequestException("设备:" + startDevice.getDevice_code() + "或设备:" + nextDevice.getDevice_code() + "地址值!"); } String msg = "当前设备:" + device_code + ",下发指令:" @@ -633,7 +640,6 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i hongXiangConveyorDeviceDriver.writing("to_open_door", "1"); hongXiangConveyorDeviceDriver.writing("to_open_door", "1"); } - this.setNow_steps_type(2); this.setRequireSucess(true); notCreateInstMessage = ""; notCreateTaskMessage = ""; @@ -822,45 +828,38 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i int error = hongXiangConveyorDeviceDriver.getError(); int move = hongXiangConveyorDeviceDriver.getMove(); if (mode == 1 && door == 1 && action == 1 && error == 0 && error1 == 0 && move == 1) { - if (this.getNow_steps_type() == 2) { - map.put("code", "to_command"); - map.put("value", "2"); - list.add(map); - this.writing(list); - this.setNow_steps_type(3); - } - } else { - if (this.getNow_steps_type() == 2) { - feedMessage = "烘箱:" + hongXiangConveyorDeviceDriver.getDevice_code(); - if (mode != 1) { - feedMessage = feedMessage + "工作模式(mode)信号未联机,"; - } - if (door != 1) { - feedMessage = feedMessage + "门状态(door)信号未开门,"; - } - if (action != 1) { - feedMessage = feedMessage + "允许取放(action)信号未允许取放,"; - } - if (move != 1) { - feedMessage = feedMessage + "取货位光电信号(move)不应该为无货状态,"; - } - if (error1 != 0) { - feedMessage = feedMessage + "故障(error1)信号出现故障,故障值:" + error1 + "。"; - } - } - } - } else { - if (this.getNow_steps_type() == 2) { map.put("code", "to_command"); map.put("value", "2"); list.add(map); this.writing(list); - this.setNow_steps_type(3); + this.setRequireActionSucess(true); + } else { + feedMessage = "烘箱:" + hongXiangConveyorDeviceDriver.getDevice_code(); + if (mode != 1) { + feedMessage = feedMessage + "工作模式(mode)信号未联机,"; + } + if (door != 1) { + feedMessage = feedMessage + "门状态(door)信号未开门,"; + } + if (action != 1) { + feedMessage = feedMessage + "允许取放(action)信号未允许取放,"; + } + if (move != 1) { + feedMessage = feedMessage + "取货位光电信号(move)不应该为无货状态,"; + } + if (error1 != 0) { + feedMessage = feedMessage + "故障(error1)信号出现故障,故障值:" + error1 + "。"; + } } + } else { + map.put("code", "to_command"); + map.put("value", "2"); + list.add(map); + this.writing(list); + this.setRequireActionSucess(true); } } } else { - if (this.getNow_steps_type() == 2) { feedMessage = "行架机械手:"; if (mode != 3) { feedMessage = feedMessage + "工作模式(mode)不为运行中状态,"; @@ -874,7 +873,6 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i if (task == 0) { feedMessage = feedMessage + "当前上报任务号(task)不应该为0。"; } - } } //取货完成关闭烘箱门 @@ -886,32 +884,32 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i HongXiangConveyorDeviceDriver hongXiangConveyorDeviceDriver; if (device.getDeviceDriver() instanceof HongXiangConveyorDeviceDriver) { hongXiangConveyorDeviceDriver = (HongXiangConveyorDeviceDriver) device.getDeviceDriver(); - map.put("to_close_door", "1"); - hongXiangConveyorDeviceDriver.writing(map); - } - if (this.getNow_steps_type() == 3) { - map.put("code", "to_command"); - map.put("value", "3"); - list.add(map); - this.writing(list); - this.setNow_steps_type(4); + Map map1 = new HashMap(); + ArrayList list1 = new ArrayList(); + map1.put("code", "to_close_door"); + map1.put("value", "1"); + list1.add(map1); + hongXiangConveyorDeviceDriver.writing(list1); } + map.put("code", "to_command"); + map.put("value", "3"); + list.add(map); + this.writing(list); + this.setRequireActionSucess(true); } } else { - if (this.getNow_steps_type() == 3) { - feedMessage = "行架机械手:"; - if (mode != 3) { - feedMessage = feedMessage + "工作模式(mode)不为运行中状态,"; - } - if (action != 2) { - feedMessage = feedMessage + "动作信号(action)不为取货完成状态,"; - } - if (move != 1) { - feedMessage = feedMessage + "光电信号(move)不为有货状态,"; - } - if (task == 0) { - feedMessage = feedMessage + "当前上报任务号(task)不应该为0。"; - } + feedMessage = "行架机械手:"; + if (mode != 3) { + feedMessage = feedMessage + "工作模式(mode)不为运行中状态,"; + } + if (action != 2) { + feedMessage = feedMessage + "动作信号(action)不为取货完成状态,"; + } + if (move != 1) { + feedMessage = feedMessage + "光电信号(move)不为有货状态,"; + } + if (task == 0) { + feedMessage = feedMessage + "当前上报任务号(task)不应该为0。"; } } @@ -931,59 +929,49 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i int error = hongXiangConveyorDeviceDriver.getError(); int move = hongXiangConveyorDeviceDriver.getMove(); if (mode == 1 && door == 1 && action == 1 && error == 0 && error1 == 0 && move == 0) { - if (this.getNow_steps_type() == 4) { - map.put("code", "to_command"); - map.put("value", "4"); - list.add(map); - this.writing(list); - this.setNow_steps_type(5); - } else { - feedMessage = "未反馈电气信号原因:当前步骤不为允许放货(now_steps_type!=4)"; - } - } else { - if (this.getNow_steps_type() == 4) { - feedMessage = "烘箱:" + hongXiangConveyorDeviceDriver.getDevice_code(); - if (mode != 1) { - feedMessage = feedMessage + "工作模式(mode)信号未联机,"; - } - if (door != 1) { - feedMessage = feedMessage + "门状态(door)信号未开门,"; - } - if (action != 1) { - feedMessage = feedMessage + "允许取放(action)信号未允许取放,"; - } - if (move != 0) { - feedMessage = feedMessage + "放货位光电信号不应该为有货状态"; - } - if (error1 != 0) { - feedMessage = feedMessage + "故障(error1)信号出现故障。"; - } - } - } - } else { - if (this.getNow_steps_type() == 4) { map.put("code", "to_command"); map.put("value", "4"); list.add(map); this.writing(list); - this.setNow_steps_type(5); + this.setRequireActionSucess(true); + } else { + feedMessage = "烘箱:" + hongXiangConveyorDeviceDriver.getDevice_code(); + if (mode != 1) { + feedMessage = feedMessage + "工作模式(mode)信号未联机,"; + } + if (door != 1) { + feedMessage = feedMessage + "门状态(door)信号未开门,"; + } + if (action != 1) { + feedMessage = feedMessage + "允许取放(action)信号未允许取放,"; + } + if (move != 0) { + feedMessage = feedMessage + "放货位光电信号不应该为有货状态"; + } + if (error1 != 0) { + feedMessage = feedMessage + "故障(error1)信号出现故障。"; + } } + } else { + map.put("code", "to_command"); + map.put("value", "4"); + list.add(map); + this.writing(list); + this.setRequireActionSucess(true); } } else { - if (this.getNow_steps_type() == 4) { - feedMessage = "行架机械手:"; - if (mode != 3) { - feedMessage = feedMessage + "工作模式(mode)不为运行中状态,"; - } - if (action != 3) { - feedMessage = feedMessage + "动作信号(action)不为放货中状态,"; - } - if (move != 1) { - feedMessage = feedMessage + "光电信号(move)不为有货状态,"; - } - if (task == 0) { - feedMessage = feedMessage + "当前上报任务号(task)不应该为0。"; - } + feedMessage = "行架机械手:"; + if (mode != 3) { + feedMessage = feedMessage + "工作模式(mode)不为运行中状态,"; + } + if (action != 3) { + feedMessage = feedMessage + "动作信号(action)不为放货中状态,"; + } + if (move != 1) { + feedMessage = feedMessage + "光电信号(move)不为有货状态,"; + } + if (task == 0) { + feedMessage = feedMessage + "当前上报任务号(task)不应该为0。"; } } @@ -1000,7 +988,12 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i LampThreecolorDeviceDriver lampThreecolorDeviceDriver; if (nextDevice.getDeviceDriver() instanceof HongXiangConveyorDeviceDriver) { hongXiangConveyorDeviceDriver = (HongXiangConveyorDeviceDriver) nextDevice.getDeviceDriver(); - hongXiangConveyorDeviceDriver.writing("to_close_door", "1"); + Map map1 = new HashMap(); + ArrayList list1 = new ArrayList(); + map1.put("code", "to_close_door"); + map1.put("value", "1"); + list1.add(map1); + hongXiangConveyorDeviceDriver.writing(list1); if (StrUtil.isNotEmpty(taskDto.getOven_time())) { //下发烘箱时间 int time = Integer.parseInt(taskDto.getOven_time()); @@ -1038,8 +1031,7 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i map.put("value", "5"); list.add(map); this.writing(list); - this.setNow_steps_type(6); - this.setNow_steps_type(0); + this.setRequireActionSucess(true); try { finish_instruction(inst2); } catch (Exception e) { @@ -1049,7 +1041,6 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i } } } else { - if (this.getNow_steps_type() == 5) { feedMessage = "行架机械手:"; if (mode != 3) { feedMessage = feedMessage + "工作模式(mode)不为运行中状态,"; @@ -1063,7 +1054,6 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i if (task == 0) { feedMessage = feedMessage + "当前上报任务号(task)不应该为0。"; } - } } } } @@ -1113,6 +1103,10 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i if (error == 0 && iserror) { this.setMessage(LangProcess.msg("universal_message4")); } + String requireActionSucess = "请求动作已复位"; + if(this.requireActionSucess){ + requireActionSucess = "请求动作未复位"; + } jo.put("device_name", this.getDevice().getDevice_name()); jo.put("mode", mode); jo.put("move", move); @@ -1126,6 +1120,7 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i jo.put("notCreateTaskMessage", notCreateTaskMessage); jo.put("notCreateInstMessage", notCreateInstMessage); jo.put("feedMessage", feedMessage); + jo.put("requireActionSucess", requireActionSucess); jo.put("driver_type", "siemens_conveyor"); jo.put("is_click", true); jo.put("x", x_position); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/system/service/quartz/config/JobRunner.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/system/service/quartz/config/JobRunner.java index 2504f2f57..a1334e810 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/system/service/quartz/config/JobRunner.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/system/service/quartz/config/JobRunner.java @@ -17,7 +17,7 @@ import java.util.List; @Component @RequiredArgsConstructor @Order(100) -@ConditionalOnProperty(value = "spring.profiles.active",havingValue = "dev") +@ConditionalOnProperty(value = "spring.profiles.active",havingValue = "prod") public class JobRunner implements ApplicationRunner { private static final Logger log = LoggerFactory.getLogger(JobRunner.class); private final ISysQuartzJobService quartzJobService; diff --git a/acs2/nladmin-ui/src/views/acs/monitor/device/index2.vue b/acs2/nladmin-ui/src/views/acs/monitor/device/index2.vue index febabca33..381744162 100644 --- a/acs2/nladmin-ui/src/views/acs/monitor/device/index2.vue +++ b/acs2/nladmin-ui/src/views/acs/monitor/device/index2.vue @@ -350,6 +350,24 @@ export default { } else if (val === 'mode') { const obj = { name: '模式', value: data[val] } arr.push(obj) + } else if (val === 'container_type') { + const obj = { name: '托盘类型', value: data[val] } + this.arr.push(obj) + } else if (val === 'command') { + const obj = { name: '作业状态', value: data[val] } + this.arr.push(obj) + } else if (val === 'prohibitInWarehouse') { + const obj = { name: '禁止入库', value: data[val] } + this.arr.push(obj) + } else if (val === 'prohibitOutWarehouse') { + const obj = { name: '禁止出库', value: data[val] } + this.arr.push(obj) + } else if (val === 'stopReceiveTask') { + const obj = { name: '停止接收任务', value: data[val] } + this.arr.push(obj) + } else if (val === 'hand_barcode') { + const obj = { name: '条码', value: data[val] } + this.arr.push(obj) } else if (val === 'error') { const obj = { name: '报警', value: data[val] } arr.push(obj)