From 87b87a84e89692460facc94cdb87c1790868f325 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=91=A8=E4=BF=8A=E6=9D=B0?= <9463626+zhou-junjiezjj@user.noreply.gitee.com> Date: Wed, 9 Aug 2023 13:48:52 +0800 Subject: [PATCH] =?UTF-8?q?rev=20=E9=A9=B1=E5=8A=A8=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/DeviceServiceImpl.java | 9 +++- .../acs/device_driver/RequestMethodEnum.java | 2 +- ...nshPalletizingManipulatorDeviceDriver.java | 2 +- .../StandardEmptyPalletSiteDeviceDriver.java | 2 +- .../lnsh/lnsh_palletizing_manipulator.vue | 53 +++++++++---------- .../acs/device/driver/lnsh/lnsh_station.vue | 43 +++++++-------- 6 files changed, 53 insertions(+), 58 deletions(-) diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device/service/impl/DeviceServiceImpl.java b/acs/nladmin-system/src/main/java/org/nl/acs/device/service/impl/DeviceServiceImpl.java index 7feb516..7b7efd2 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device/service/impl/DeviceServiceImpl.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device/service/impl/DeviceServiceImpl.java @@ -1223,7 +1223,14 @@ public class DeviceServiceImpl implements DeviceService, ApplicationAutoInitial "false".equalsIgnoreCase(json.getString("extra_value"))) { extraObj.put(json.getString("extra_code"), json.getBoolean("extra_value")); } else { - extraObj.put(json.getString("extra_code"), json.get("extra_value")); + boolean endsWith = json.getString("extra_value").endsWith("]"); + boolean startsWith = json.getString("extra_value").startsWith("["); + if (endsWith && startsWith){ + JSONArray extraValue = JSONArray.parseArray(json.getString("extra_value")); + extraObj.put(json.getString("extra_code"), extraValue); + } else { + extraObj.put(json.getString("extra_code"), json.get("extra_value")); + } } } diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/RequestMethodEnum.java b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/RequestMethodEnum.java index e7910e1..0937a7b 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/RequestMethodEnum.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/RequestMethodEnum.java @@ -42,7 +42,7 @@ public enum RequestMethodEnum { feedback_device_status(16, "feedback_device_status", "反馈设备状态","1"), - apply_feedback_weight(16, "apply_feedback_weight", "反馈压机残留重量","0"); + apply_feedback_weight(16, "apply_feedback_weight", "反馈压机残留重量","1"); //驱动索引 diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/lnsh_palletizing_manipulator/LnshPalletizingManipulatorDeviceDriver.java b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/lnsh_palletizing_manipulator/LnshPalletizingManipulatorDeviceDriver.java index 5a567e2..0b6e0b1 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/lnsh_palletizing_manipulator/LnshPalletizingManipulatorDeviceDriver.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/lnsh/lnsh_palletizing_manipulator/LnshPalletizingManipulatorDeviceDriver.java @@ -674,7 +674,7 @@ public class LnshPalletizingManipulatorDeviceDriver extends AbstractOpcDeviceDri request.setRequest_medthod_name(RequestMethodEnum.getName(Thread.currentThread().getStackTrace()[1].getMethodName())); List getDeviceCodeList = this.getExtraDeviceCodes("get_station"); List putDeviceCodeList = this.getExtraDeviceCodes("put_station"); - request.setGet_station(getDeviceCodeList.get(get_station)); + request.setGet_station(getDeviceCodeList.get(0)); request.setPut_station(putDeviceCodeList.get(put_station)); request.setLaser_marking_code(laser_marking_code); request.setGrinding_number(grinding_number); diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/standard_emptypallet_site/StandardEmptyPalletSiteDeviceDriver.java b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/standard_emptypallet_site/StandardEmptyPalletSiteDeviceDriver.java index 8b49362..8f6041d 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/standard_emptypallet_site/StandardEmptyPalletSiteDeviceDriver.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/standard_emptypallet_site/StandardEmptyPalletSiteDeviceDriver.java @@ -186,7 +186,7 @@ public class StandardEmptyPalletSiteDeviceDriver extends AbstractOpcDeviceDriver if (number == max_emptypalletnum && !requireSucess && move > 0) { //判断逻辑 //需要检查关联的另一设备也满足数量后才能入库 - Object[] linkobj = (Object[]) this.getDevice().getExtraValue().get("link_device_code"); + Object[] linkobj = (Object[]) this.getDevice().getExtraValue().get("device_code"); for (int i = 0; i < linkobj.length; i++) { String linkDevice = linkobj[i].toString(); Device device = appService.findDeviceByCode(linkDevice); diff --git a/acs/nladmin-ui/src/views/acs/device/driver/lnsh/lnsh_palletizing_manipulator.vue b/acs/nladmin-ui/src/views/acs/device/driver/lnsh/lnsh_palletizing_manipulator.vue index c3c703c..97eef60 100644 --- a/acs/nladmin-ui/src/views/acs/device/driver/lnsh/lnsh_palletizing_manipulator.vue +++ b/acs/nladmin-ui/src/views/acs/device/driver/lnsh/lnsh_palletizing_manipulator.vue @@ -199,27 +199,27 @@ 交互相关:
- - - - - 新增一行 - - + + + + + 新增一行 + +
@@ -241,7 +241,7 @@ - + - +