From a62fc01c617ed7d6837d897a120905c2b307ad89 Mon Sep 17 00:00:00 2001 From: wu <731351411@qq.com> Date: 星期一, 22 一月 2024 09:02:28 +0800 Subject: [PATCH] 增加汇报写入判断限制 --- springboot-vue3/src/main/java/com/example/springboot/entity/device/PlcParameterObject.java | 20 ++++++++++++++++++++ 1 files changed, 20 insertions(+), 0 deletions(-) diff --git a/springboot-vue3/src/main/java/com/example/springboot/entity/device/PlcParameterObject.java b/springboot-vue3/src/main/java/com/example/springboot/entity/device/PlcParameterObject.java index 163c45e..56a0230 100644 --- a/springboot-vue3/src/main/java/com/example/springboot/entity/device/PlcParameterObject.java +++ b/springboot-vue3/src/main/java/com/example/springboot/entity/device/PlcParameterObject.java @@ -64,6 +64,8 @@ return null; } + + /** * 鏍规嵁鍙傛暟鏍囪瘑 鑾峰彇鏌愪釜鍙傛暟瀹炰緥 * @@ -80,6 +82,24 @@ } return arrayList; } + + + public List<String> getPlcAddressList(String codeid) { + List<String> addressList = new ArrayList<>(); + if (plcParameterList != null) { + for (PlcParameterInfo plcParameterInfo : plcParameterList) { + if (plcParameterInfo.getCodeId().equals(codeid)) { + int plcAddress = plcParameterInfo.getPlcAddress(); + if (!addressList.contains(plcAddress)) { + addressList.add(String.valueOf(plcAddress)); + } + } + } + } + return addressList; + } + + /** * 娣诲姞鍙傛暟瀹炰緥 -- Gitblit v1.8.0