From 83f222c9eebcee8db94d41a081596506f60f9775 Mon Sep 17 00:00:00 2001
From: lty <876263681@qq.com>
Date: 星期二, 05 八月 2025 16:59:45 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/core/model/protocol/RgvProtocol.java |   45 +++++++++++++++++++++++++++++++++------------
 1 files changed, 33 insertions(+), 12 deletions(-)

diff --git a/src/main/java/com/zy/core/model/protocol/RgvProtocol.java b/src/main/java/com/zy/core/model/protocol/RgvProtocol.java
index d952086..1241c1d 100644
--- a/src/main/java/com/zy/core/model/protocol/RgvProtocol.java
+++ b/src/main/java/com/zy/core/model/protocol/RgvProtocol.java
@@ -5,11 +5,14 @@
 import com.zy.core.enums.RgvStatusType;
 import lombok.Data;
 
+import java.util.HashMap;
+import java.util.Map;
+
 /**
  * Created by vincent on 2020/8/7
  */
 @Data
-public class RgvProtocol {
+public class RgvProtocol implements Cloneable{
 
     private Integer RgvNo;
 
@@ -162,15 +165,15 @@
         this.status1 = RgvStatusType.get(type1).id.shortValue();
     }
 
-    public void setStatus2(Short status2){
-        this.status2 = status2;
-        this.statusType2 = RgvStatusType.get(status2);
-    }
-
-    public void setStatus2(RgvStatusType type2){
-        this.statusType2 = type2;
-        this.status2 = RgvStatusType.get(type2).id.shortValue();
-    }
+//    public void setStatus2(Short status2){
+//        this.status2 = status2;
+//        this.statusType2 = RgvStatusType.get(status2);
+//    }
+//
+//    public void setStatus2(RgvStatusType type2){
+//        this.statusType2 = type2;
+//        this.status2 = RgvStatusType.get(type2).id.shortValue();
+//    }
 
     /**
      * 鏈�杩戜竴娆″叆鍑哄簱绫诲瀷
@@ -185,7 +188,7 @@
             basRgv.setRgvErr(alarm.longValue());
         }
         basRgv.setWrkNo1(taskNo1.intValue());
-        basRgv.setWrkNo2(taskNo2.intValue());
+//        basRgv.setWrkNo2(taskNo2.intValue());
         return basRgv;
     }
 
@@ -203,8 +206,26 @@
 
     public Integer getRgvPosI(){
         //闇�瑕佹牴鎹幇鍦烘敼閫�  鏍规嵁璇诲埌鐨勫�艰幏鍙栧搴旂珯鐐逛綅缃�
+        Map<Short,Integer> map = new HashMap<>();
+        map.put((short) 1,100);map.put((short) 2,101);
+        map.put((short) 3,106);map.put((short) 4,107);
+        map.put((short) 5,112);map.put((short) 6,113);
+       map.put((short) 7,124); map.put((short) 8,119);
+        map.put((short) 9,149);map.put((short) 10,153);
+        map.put((short) 11,157);map.put((short) 12,161);
         if (RgvPos==null) return 0;
-        return RgvPos.intValue();
+
+        return map.get(RgvPos);
+    }
+
+    @Override
+    public RgvProtocol clone() {
+        try {
+            return (RgvProtocol) super.clone();
+        } catch (CloneNotSupportedException e) {
+            e.printStackTrace();
+        }
+        return null;
     }
 
 }

--
Gitblit v1.9.1