huangxingxing 2 anni fa
parent
commit
76d60afef4

+ 2 - 1
definitionsrc/returncode/returncode-business.properties

@@ -88,5 +88,6 @@ EB4000010 = \u65E0\u51E0\u4F55\u6570\u636E\uFF01
 EB4000011 = \u914D\u7F6EID\u9519\u8BEF\uFF01
 EB4000012 = \u6CA1\u6709grid\u6587\u4EF6\uFF01
 EB4000013 = vector\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01
-EB4000014 = \u5207\u7247Lst\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01
+EB4000014 = \u5207\u7247List\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01
 EB4000015 = \u8BF7\u4E0A\u4F20\u6587\u4EF6\uFF01
+EB4000016 = stream\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01

+ 2 - 1
definitionsrc/returncode/returncode-business_zh_CN.properties

@@ -88,5 +88,6 @@ EB4000010 = \u65E0\u51E0\u4F55\u6570\u636E\uFF01
 EB4000011 = \u914D\u7F6EID\u9519\u8BEF\uFF01
 EB4000012 = \u6CA1\u6709grid\u6587\u4EF6\uFF01
 EB4000013 = vector\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01
-EB4000014 = \u5207\u7247Lst\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01
+EB4000014 = \u5207\u7247List\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01
 EB4000015 = \u8BF7\u4E0A\u4F20\u6587\u4EF6\uFF01
+EB4000016 = stream\u6E32\u67D3\u53C2\u6570\u5B58\u5728\u9519\u8BEF\uFF01

+ 39 - 0
generated/com/miniframe/generate/comm/system/A_AFT001.java

@@ -269,4 +269,43 @@ public class A_AFT001 extends BaseMapModel implements Serializable {
 	public String getIndex() {
 		return this.index;
 	}
+	String x;//x
+	/**
+	 *x
+	 */
+	public void setX(String x) {
+		this.x=x;
+	}
+	/**
+	 *x
+	 */
+	public String getX() {
+		return this.x;
+	}
+	String y;//y
+	/**
+	 *y
+	 */
+	public void setY(String y) {
+		this.y=y;
+	}
+	/**
+	 *y
+	 */
+	public String getY() {
+		return this.y;
+	}
+	String z;//z
+	/**
+	 *z
+	 */
+	public void setZ(String z) {
+		this.z=z;
+	}
+	/**
+	 *z
+	 */
+	public String getZ() {
+		return this.z;
+	}
 }

+ 39 - 0
generated/validateform/a_aft001Form.xml

@@ -251,6 +251,45 @@
       <var-value>1024</var-value>
     </var>
 </field>
+<field property="x" depends="minlength,maxlength">
+    <arg0 key="a_aft001.x"/>
+    <arg1 name="minlength" key="${var:minlength}"/>
+    <var>
+      <var-name>minlength</var-name>
+      <var-value>1</var-value>
+    </var>
+    <arg1 name="maxlength" key="${var:maxlength}"/>
+    <var>
+      <var-name>maxlength</var-name>
+      <var-value>2048</var-value>
+    </var>
+</field>
+<field property="y" depends="minlength,maxlength">
+    <arg0 key="a_aft001.y"/>
+    <arg1 name="minlength" key="${var:minlength}"/>
+    <var>
+      <var-name>minlength</var-name>
+      <var-value>1</var-value>
+    </var>
+    <arg1 name="maxlength" key="${var:maxlength}"/>
+    <var>
+      <var-name>maxlength</var-name>
+      <var-value>2048</var-value>
+    </var>
+</field>
+<field property="z" depends="minlength,maxlength">
+    <arg0 key="a_aft001.z"/>
+    <arg1 name="minlength" key="${var:minlength}"/>
+    <var>
+      <var-name>minlength</var-name>
+      <var-value>1</var-value>
+    </var>
+    <arg1 name="maxlength" key="${var:maxlength}"/>
+    <var>
+      <var-name>maxlength</var-name>
+      <var-value>2048</var-value>
+    </var>
+</field>
 </form>
 </formset>
 </form-validation>

+ 3 - 0
generated/validator/resources_a_aft001Form_validator.properties

@@ -18,4 +18,7 @@ a_aft001.b = b
 a_aft001.showHideState = \u663E\u793A1\u9690\u85CF0
 a_aft001.transparency = transparency
 a_aft001.index = \u5207\u7247\u6DFB\u52A0\u5220\u9664ID
+a_aft001.x = x
+a_aft001.y = y
+a_aft001.z = z
 a_aft001Form = true

+ 3 - 0
generated/validator/resources_a_aft001Form_validator_zh_CN.properties

@@ -18,4 +18,7 @@ a_aft001.b = b
 a_aft001.showHideState = \u663E\u793A1\u9690\u85CF0
 a_aft001.transparency = transparency
 a_aft001.index = \u5207\u7247\u6DFB\u52A0\u5220\u9664ID
+a_aft001.x = x
+a_aft001.y = y
+a_aft001.z = z
 a_aft001Form = true

+ 68 - 0
src/main/java/com/miniframe/aftercure/StreamMsg.java

@@ -0,0 +1,68 @@
+package com.miniframe.aftercure;
+
+public class StreamMsg<main> {
+
+   private String  direction;//(Both,Forward,Backward)
+   private String streamstyle;//(Line,Ribbon,Tube)
+   private double initialstep;
+   private double maxpropagation;
+   private double minimumstep;
+   private Boolean showstate;
+   private Boolean toolstate;
+
+    public String getDirection() {
+        return direction;
+    }
+
+    public void setDirection(String direction) {
+        this.direction = direction;
+    }
+
+    public String getStreamstyle() {
+        return streamstyle;
+    }
+
+    public void setStreamstyle(String streamstyle) {
+        this.streamstyle = streamstyle;
+    }
+
+    public double getInitialstep() {
+        return initialstep;
+    }
+
+    public void setInitialstep(double initialstep) {
+        this.initialstep = initialstep;
+    }
+
+    public double getMaxpropagation() {
+        return maxpropagation;
+    }
+
+    public void setMaxpropagation(double maxpropagation) {
+        this.maxpropagation = maxpropagation;
+    }
+
+    public double getMinimumstep() {
+        return minimumstep;
+    }
+
+    public void setMinimumstep(double minimumstep) {
+        this.minimumstep = minimumstep;
+    }
+
+    public Boolean getShowstate() {
+        return showstate;
+    }
+
+    public void setShowstate(Boolean showstate) {
+        this.showstate = showstate;
+    }
+
+    public Boolean getToolstate() {
+        return toolstate;
+    }
+
+    public void setToolstate(Boolean toolstate) {
+        this.toolstate = toolstate;
+    }
+}

+ 61 - 2
src/main/java/com/miniframe/bisiness/system/AFT001Service.java

@@ -3,11 +3,14 @@ package com.miniframe.bisiness.system;
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Map;
+import java.util.stream.Stream;
 
 import com.alibaba.nacos.shaded.com.google.gson.JsonArray;
 import com.alibaba.nacos.shaded.com.google.gson.JsonObject;
+import com.alibaba.nacos.shaded.io.grpc.netty.shaded.io.netty.util.internal.StringUtil;
 import com.miniframe.aftercure.ActionMsg;
 import com.miniframe.aftercure.SliceMsg;
+import com.miniframe.aftercure.StreamMsg;
 import com.miniframe.constant.MFConstant;
 import com.miniframe.core.ExecProcessFlow;
 import com.miniframe.core.exception.BusinessException;
@@ -197,7 +200,6 @@ public class AFT001Service extends AFT001BaseModel implements ExecProcessFlow {
 			msg.setParamJson(obj.toString());
 		}else if(action.equals("SliceDisplayUpdate")){
 
-
 		}else if(action.equals("SliceDisplayDel")){
 			String index = this.getA_aft001().getIndex();
 			JSONObject obj  = new JSONObject();
@@ -207,11 +209,68 @@ public class AFT001Service extends AFT001BaseModel implements ExecProcessFlow {
 			try {
 				List<SliceMsg> list = XiJsonUtil.jsonToList(paramJson,SliceMsg.class);
 				msg.setParamJson(paramJson);
-				System.out.println(XiJsonUtil.objectToJson(list));
 			}catch (Exception e){
 				throw new BusinessException("EB4000014");
 			}
+		}else if(action.equals("StreamDisplayCreate")){
+			try {
+
+				String x = this.getA_aft001().getX();
+				String y = this.getA_aft001().getY();
+				String z = this.getA_aft001().getZ();
+				String u=this.getA_aft001().getDataU();
+				String v=this.getA_aft001().getDataV();
+				String w=this.getA_aft001().getDataW();
+				if(StringUtil.isNullOrEmpty(x)
+						||StringUtil.isNullOrEmpty(y)
+						||StringUtil.isNullOrEmpty(z)
+						||StringUtil.isNullOrEmpty(w)
+						||StringUtil.isNullOrEmpty(u)
+						||StringUtil.isNullOrEmpty(v)
+				){
+					throw new BusinessException("EB4000016");
+				}
+				JSONObject obj  = new JSONObject();
+				obj.put("x",x);
+				obj.put("y",y);
+				obj.put("z",z);
+				obj.put("u",u);
+				obj.put("v",v);
+				obj.put("w",w);
+				msg.setParamJson(obj.toString());
+			}catch (Exception e){
+				throw new BusinessException("EB4000016");
+			}
+		}else if(action.equals("StreamDisplayDeleteAll")){
+
+		}else if(action.equals("StreamDisplayApply")){
+			try{
+				StreamMsg streamMsg= XiJsonUtil.jsonToPojo(paramJson, StreamMsg.class);
+				if(StringUtil.isNullOrEmpty(streamMsg.getDirection())){
+					throw new BusinessException("EB4000014");
+				}
+				//Both,Forward,Backward
+				if(!"Both".equals(streamMsg.getDirection())
+				&&!"Forward".equals(streamMsg.getDirection())
+				&&!"Backward".equals(streamMsg.getDirection())){
+					throw new BusinessException("EB4000014");
+				}
+				if(StringUtil.isNullOrEmpty(streamMsg.getStreamstyle())){
+					throw new BusinessException("EB4000014");
+				}
+				//(Line,Ribbon,Tube)
+				if(!"Line".equals(streamMsg.getStreamstyle())
+						&&!"Ribbon".equals(streamMsg.getStreamstyle())
+						&&!"Tube".equals(streamMsg.getStreamstyle())){
+					throw new BusinessException("EB4000014");
+				}
+				msg.setParamJson(paramJson);
+			}catch (Exception e){
+				throw new BusinessException("EB4000014");
+			}
+
 		}
+
 		MFMqUtils.get(CaeMQ.class).sendCaein(XiJsonUtil.objectToJson(msg));
 
 	}

+ 7 - 7
src/main/java/com/miniframe/service/mq/CaeMQ.java

@@ -46,7 +46,7 @@ public class CaeMQ extends CaeViewMFMqDynamic {
     public CaeMQ(MFMqConfig mfMqConfig) {
         super(mfMqConfig);
 //        setLocalMqOp(new CaeMqOp(),"caedyout");//设置监听
-        setLocalMqOp(new CaeMqOp(),"caeout");//设置监听
+        setLocalMqOp(new CaeMqOp(),"caeoutt");//设置监听
 //        setDefOp(new CaeMqOp());//设置默认监听
     }
 
@@ -57,7 +57,7 @@ public class CaeMQ extends CaeViewMFMqDynamic {
 
     @Override
     public String[] declareListenerQueueLocal(){
-        return new String[]{"caeout"};
+        return new String[]{"caeoutt"};
 //        return new String[]{};
     }
 
@@ -67,8 +67,8 @@ public class CaeMQ extends CaeViewMFMqDynamic {
         //TTLMS: 0,不设置x-message-ttl 参数
         //enableDlx : false 不申明dlx queue
         List<MFMqInfo> mfMqInfoList=new ArrayList<>();
-        mfMqInfoList.add(new MFMqInfo("caein","caein",0,false,MFMqInfo.MFMQExchangeType.GLOBAL_DATA));
-        mfMqInfoList.add(new MFMqInfo("caeout","caeout",0,false,MFMqInfo.MFMQExchangeType.GLOBAL_DATA));
+        mfMqInfoList.add(new MFMqInfo("caeint","caeint",0,false,MFMqInfo.MFMQExchangeType.GLOBAL_DATA));
+        mfMqInfoList.add(new MFMqInfo("caeoutt","caeoutt",0,false,MFMqInfo.MFMQExchangeType.GLOBAL_DATA));
         return mfMqInfoList;
     }
 
@@ -77,14 +77,14 @@ public class CaeMQ extends CaeViewMFMqDynamic {
      * @param data
      */
     public void sendCaein(String data){
-        sendData("caein",data);
+        sendData("caeint",data);
     }
     /**
      * 向未处理信息队列 发送消息
      * @param data
      */
     public void sendCaeout(String data){
-        sendData("caeout",data);
+        sendData("caeoutt",data);
     }
 
     /**
@@ -93,7 +93,7 @@ public class CaeMQ extends CaeViewMFMqDynamic {
     public static class CaeMqOp implements IMFMqOp {
         @Override
         public boolean handle(String data, long deliveryTag, Map<String, Object> headers, Channel channel) throws Exception {
-//            System.out.println("Queue : "+getAMQPConsumerQueue(headers)+", Data : "+ data);
+            System.out.println("Queue : "+getAMQPConsumerQueue(headers)+", Data : "+ data);
            try {
                ActionMsg msg= XiJsonUtil.jsonToPojo(data, ActionMsg.class);
                WebsocketEndPoint point =  (WebsocketEndPoint) UtilTools.getBean("websocketEndPoint");

+ 22 - 6
src/test/java/com/miniframe/FileMain.java

@@ -2,6 +2,7 @@ package com.miniframe;
 
 import com.fasterxml.jackson.core.JsonProcessingException;
 import com.miniframe.aftercure.SliceMsg;
+import com.miniframe.aftercure.StreamMsg;
 import com.miniframe.tools.XIDateTimeUtils;
 import com.miniframe.tools.XiJsonUtil;
 
@@ -71,12 +72,16 @@ public class FileMain {
 //        File file =new File(pathDir);
 //        allFiles(file);
 
-        List<SliceMsg> b =new ArrayList<>();
-        for (int i = 1; i <3 ; i++) {
-            b.add( inib(i));
-        }
-        String t= XiJsonUtil.objectToJson(b);
-        System.out.println(t);
+//        List<SliceMsg> b =new ArrayList<>();
+//        for (int i = 1; i <3 ; i++) {
+//            b.add( inib(i));
+//        }
+
+//        String t= XiJsonUtil.objectToJson(b);
+//        System.out.println(t);
+
+        StreamMsg b =inic();
+        System.out.println(XiJsonUtil.objectToJson(b));
     }
 
     private static SliceMsg inib(int id) {
@@ -100,6 +105,17 @@ public class FileMain {
         return b;
     }
 
+    private static StreamMsg inic() {
+        StreamMsg b =new StreamMsg();
+        b.setDirection("Both");
+        b.setStreamstyle("Line");
+        b.setInitialstep(0.2);
+        b.setMaxpropagation(1.2);
+        b.setMinimumstep(0.3);
+        b.setShowstate(true);
+        b.setToolstate(true);
+        return b;
+    }
 
 
 }

+ 3 - 2
系统设计/数据定义/返 回 码/business(业务系统).csv

@@ -100,6 +100,7 @@
 4000011,EB4000011,配置ID错误!
 4000012,EB4000012,没有grid文件!
 4000013,EB4000013,vector 渲染参数存在错误!
-4000014,EB4000014,切片Lst 渲染参数存在错误!
+4000014,EB4000014,切片List 渲染参数存在错误!
 
-4000015,EB4000015,请上传文件!
+4000015,EB4000015,请上传文件!
+4000016,EB4000016,stream 渲染参数存在错误!

+ 4 - 1
系统设计/通信设计/通讯报文/system(系统服务)/报文体/AFT001_A(后处理消息操作消息发送).csv

@@ -18,4 +18,7 @@
 17,b,b,string,,,,1,2048,,,,,,
 18,showHideState,显示1隐藏0,string,,,,1,2048,,,,,,
 19,transparency,transparency,string,,,,1,2048,,,,,,
-20,index,切片添加删除ID,string,,,,1,1024,,,,,,
+20,index,切片添加删除ID,string,,,,1,1024,,,,,,
+21,x,x,string,,,,1,2048,,,,,,
+22,y,y,string,,,,1,2048,,,,,,
+23,z,z,string,,,,1,2048,,,,,,