瀏覽代碼

组件链接复制

huangxingxing 7 小時之前
父節點
當前提交
8d61555768
共有 25 個文件被更改,包括 606 次插入1 次删除
  1. 1 0
      dbscript/init/generate/03-functionInit.sql
  2. 112 0
      generated/com/miniframe/generate/business/es/model/ES0029BaseModel.java
  3. 65 0
      generated/com/miniframe/generate/comm/es/A_ES0029.java
  4. 25 0
      generated/com/miniframe/generate/comm/es/A_ES0029_PCCIDS_RECODE.java
  5. 25 0
      generated/com/miniframe/generate/comm/es/A_ES0029_PCIDS_RECODE.java
  6. 25 0
      generated/com/miniframe/generate/comm/es/D_ES0029.java
  7. 99 0
      generated/com/miniframe/generate/comm/httpesapater/ES0029Client.java
  8. 12 0
      generated/validateform/a_es0029Form.xml
  9. 12 0
      generated/validateform/d_es0029Form.xml
  10. 3 0
      generated/validator/resources_a_es0029Form_validator.properties
  11. 3 0
      generated/validator/resources_a_es0029Form_validator_zh_CN.properties
  12. 2 0
      generated/validator/resources_a_es0029_pccids_recodeForm_validator.properties
  13. 2 0
      generated/validator/resources_a_es0029_pccids_recodeForm_validator_zh_CN.properties
  14. 2 0
      generated/validator/resources_a_es0029_pcids_recodeForm_validator.properties
  15. 2 0
      generated/validator/resources_a_es0029_pcids_recodeForm_validator_zh_CN.properties
  16. 2 0
      generated/validator/resources_d_es0029Form_validator.properties
  17. 2 0
      generated/validator/resources_d_es0029Form_validator_zh_CN.properties
  18. 135 0
      src/main/java/com/miniframe/bisiness/es/ES0029Service.java
  19. 13 0
      src/main/java/com/miniframe/mappers/es/model/PcCopyVo.java
  20. 1 1
      src/test/java/com/miniframe/ApplicationTests.java
  21. 6 0
      src/test/java/com/miniframe/base64Test.java
  22. 44 0
      src/test/java/com/miniframe/comm/httpesapater/ES0029Test.java
  23. 4 0
      系统设计/系统模块/ES(无锡发动机).csv
  24. 7 0
      系统设计/通信设计/通讯报文/es(无锡发动机)/报文体/ES0029_A(组件复制).csv
  25. 2 0
      系统设计/通信设计/通讯报文/es(无锡发动机)/报文体/ES0029_D(组件复制).csv

+ 1 - 0
dbscript/init/generate/03-functionInit.sql

@@ -30,6 +30,7 @@ INSERT INTO SYS_FUNCTION(FUNCTIONID, CLASSNAME, FUNCTIONNAME ,ENABLE)VALUES ('ES
 INSERT INTO SYS_FUNCTION(FUNCTIONID, CLASSNAME, FUNCTIONNAME ,ENABLE)VALUES ('ES0026', '无锡发动机','单位系统删除',true);
 INSERT INTO SYS_FUNCTION(FUNCTIONID, CLASSNAME, FUNCTIONNAME ,ENABLE)VALUES ('ES0027', '无锡发动机','图片base64编码查询',true);
 INSERT INTO SYS_FUNCTION(FUNCTIONID, CLASSNAME, FUNCTIONNAME ,ENABLE)VALUES ('ES0028', '无锡发动机','项目克隆',true);
+INSERT INTO SYS_FUNCTION(FUNCTIONID, CLASSNAME, FUNCTIONNAME ,ENABLE)VALUES ('ES0029', '无锡发动机','组件复制',true);
 INSERT INTO SYS_FUNCTION(FUNCTIONID, CLASSNAME, FUNCTIONNAME ,ENABLE)VALUES ('ES1001', '无锡发动机','组件查询',true);
 INSERT INTO SYS_FUNCTION(FUNCTIONID, CLASSNAME, FUNCTIONNAME ,ENABLE)VALUES ('BES001', '无锡发动机','基础字典查询',true);
 -- 基础系统

+ 112 - 0
generated/com/miniframe/generate/business/es/model/ES0029BaseModel.java

@@ -0,0 +1,112 @@
+package com.miniframe.generate.business.es.model;
+
+import java.util.Map;
+import java.io.IOException;
+import java.util.LinkedHashMap;
+import com.miniframe.core.BaseMapModel;
+import com.miniframe.core.ext.UtilTools;
+import com.miniframe.core.ext.HttpMapFormater;
+import java.time.ZonedDateTime;
+import java.time.format.DateTimeFormatter;
+import com.miniframe.generate.global.AppGlobalVariableSysconfig;
+
+import com.miniframe.generate.comm.es.A_ESHEAD;
+import com.miniframe.generate.comm.es.D_ESHEAD;
+import com.miniframe.generate.comm.es.A_ES0029;
+import com.miniframe.generate.comm.es.D_ES0029;
+
+/**
+ * 无锡发动机,“组件复制”模型类(不要维护,重新生成将覆盖)。
+ */
+@SuppressWarnings({ "rawtypes", "unchecked" })
+public class ES0029BaseModel extends BaseMapModel {
+
+	private static final long serialVersionUID = -1326184831746814093L;
+
+	A_ESHEAD a_eshead;//上行头
+	D_ESHEAD d_eshead;//下行头
+	A_ES0029 a_es0029;//上行体
+	D_ES0029 d_es0029;//下行体
+
+	public ES0029BaseModel(){
+		a_eshead=new A_ESHEAD();
+		d_eshead=new D_ESHEAD();
+		a_es0029=new A_ES0029();
+		d_es0029=new D_ES0029();
+	}
+
+	public void validater() throws Exception {
+		this.a_eshead.validater();
+		this.a_es0029.validater();
+	}
+
+	public void setTransMap(Map map) throws Exception {
+		Map headMap = HttpMapFormater.format(map, A_ESHEAD.class);
+		this.a_eshead = UtilTools.map2Obj(headMap, A_ESHEAD.class);
+		Map bodyMap = HttpMapFormater.format(map, A_ES0029.class);
+		this.a_es0029 = UtilTools.map2Obj(bodyMap, A_ES0029.class);
+	}
+
+	public Map getTransMap() throws Exception {
+		Map reMap = new LinkedHashMap();
+
+		if(UtilTools.isNullOrBlank((this.d_eshead).getTransCode())){
+			(this.d_eshead).setTransCode((this.a_eshead).getTransCode());
+		}
+		if(UtilTools.isNullOrBlank((this.d_eshead).getChannelNo())){
+			(this.d_eshead).setChannelNo((this.a_eshead).getChannelNo());
+		}
+		if(UtilTools.isNullOrBlank((this.d_eshead).getUserId())){
+			(this.d_eshead).setUserId((this.a_eshead).getUserId());
+		}
+        if(UtilTools.isNullOrBlank((this.d_eshead).getTransTime())){
+            (this.d_eshead).setTransTime(DateTimeFormatter.ofPattern(AppGlobalVariableSysconfig.DATETIMEFORMAT).format(ZonedDateTime.now()));
+        }
+
+		reMap.putAll(UtilTools.obj2Map(this.d_eshead));
+		reMap.putAll(UtilTools.obj2Map(this.d_es0029));
+
+		return reMap;
+	}
+
+	public A_ESHEAD getA_eshead() {
+		return this.a_eshead;
+	}
+
+	public void setA_eshead(A_ESHEAD a_eshead) {
+		this.a_eshead=a_eshead;
+	}
+
+	public D_ESHEAD getD_eshead() {
+		return d_eshead;
+	}
+
+	public void setD_eshead(D_ESHEAD d_eshead) {
+		this.d_eshead=d_eshead;
+	}
+
+	public A_ES0029 getA_es0029() {
+		return a_es0029;
+	}
+
+	public void setA_es0029(A_ES0029 a_es0029) {
+		this.a_es0029=a_es0029;
+	}
+
+	public D_ES0029 getD_es0029() {
+		return this.d_es0029;
+	}
+
+	public void setD_es0029(D_ES0029 d_es0029) {
+		this.d_es0029=d_es0029;
+	}
+
+	@Override
+	public String toString() {
+		try {
+			return UtilTools.obj2Json(this,true);
+		} catch (IOException e) {
+			return "";
+		}
+	}
+}

+ 65 - 0
generated/com/miniframe/generate/comm/es/A_ES0029.java

@@ -0,0 +1,65 @@
+/**
+ * 无锡发动机
+ */
+package com.miniframe.generate.comm.es;
+import com.miniframe.core.BaseMapModel;
+import java.io.Serializable;
+import java.util.*;
+/**
+ * 组件复制
+ */
+public class A_ES0029 extends BaseMapModel implements Serializable {
+	private static final long serialVersionUID = -1463838678425832212L;
+	String pid;//项目编码
+	/**
+	 *项目编码
+	 */
+	public void setPid(String pid) {
+		this.pid=pid;
+	}
+	/**
+	 *项目编码
+	 */
+	public String getPid() {
+		return this.pid;
+	}
+	List <A_ES0029_PCIDS_RECODE> pcids;//复制的组件
+	/**
+	 *复制的组件
+	 */
+	public void setPcids(List <A_ES0029_PCIDS_RECODE> pcids) {
+		this.pcids=pcids;
+	}
+	/**
+	 *复制的组件
+	 */
+	public List <A_ES0029_PCIDS_RECODE> getPcids() {
+		return this.pcids;
+	}
+	List <A_ES0029_PCCIDS_RECODE> pccids;//复制的连线
+	/**
+	 *复制的连线
+	 */
+	public void setPccids(List <A_ES0029_PCCIDS_RECODE> pccids) {
+		this.pccids=pccids;
+	}
+	/**
+	 *复制的连线
+	 */
+	public List <A_ES0029_PCCIDS_RECODE> getPccids() {
+		return this.pccids;
+	}
+	String npid;//目标项目编码
+	/**
+	 *目标项目编码
+	 */
+	public void setNpid(String npid) {
+		this.npid=npid;
+	}
+	/**
+	 *目标项目编码
+	 */
+	public String getNpid() {
+		return this.npid;
+	}
+}

+ 25 - 0
generated/com/miniframe/generate/comm/es/A_ES0029_PCCIDS_RECODE.java

@@ -0,0 +1,25 @@
+/**
+ * 无锡发动机
+ */
+package com.miniframe.generate.comm.es;
+import com.miniframe.core.BaseMapModel;
+import java.io.Serializable;
+/**
+ * 组件复制->复制的连线
+ */
+public class A_ES0029_PCCIDS_RECODE extends BaseMapModel implements Serializable {
+	private static final long serialVersionUID = -1463838678425832212L;
+	String pccid;//连线编码
+	/**
+	 *连线编码
+	 */
+	public void setPccid(String pccid) {
+		this.pccid=pccid;
+	}
+	/**
+	 *连线编码
+	 */
+	public String getPccid() {
+		return this.pccid;
+	}
+}

+ 25 - 0
generated/com/miniframe/generate/comm/es/A_ES0029_PCIDS_RECODE.java

@@ -0,0 +1,25 @@
+/**
+ * 无锡发动机
+ */
+package com.miniframe.generate.comm.es;
+import com.miniframe.core.BaseMapModel;
+import java.io.Serializable;
+/**
+ * 组件复制->复制的组件
+ */
+public class A_ES0029_PCIDS_RECODE extends BaseMapModel implements Serializable {
+	private static final long serialVersionUID = -1463838678425832212L;
+	String pcid;//组件编码
+	/**
+	 *组件编码
+	 */
+	public void setPcid(String pcid) {
+		this.pcid=pcid;
+	}
+	/**
+	 *组件编码
+	 */
+	public String getPcid() {
+		return this.pcid;
+	}
+}

+ 25 - 0
generated/com/miniframe/generate/comm/es/D_ES0029.java

@@ -0,0 +1,25 @@
+/**
+ * 无锡发动机
+ */
+package com.miniframe.generate.comm.es;
+import com.miniframe.core.BaseMapModel;
+import java.io.Serializable;
+/**
+ * 组件复制
+ */
+public class D_ES0029 extends BaseMapModel implements Serializable {
+	private static final long serialVersionUID = -1463838678425832212L;
+	String cpjson;//映射结果Json
+	/**
+	 *映射结果Json
+	 */
+	public void setCpjson(String cpjson) {
+		this.cpjson=cpjson;
+	}
+	/**
+	 *映射结果Json
+	 */
+	public String getCpjson() {
+		return this.cpjson;
+	}
+}

+ 99 - 0
generated/com/miniframe/generate/comm/httpesapater/ES0029Client.java

@@ -0,0 +1,99 @@
+package com.miniframe.generate.comm.httpesapater;
+
+import com.miniframe.spring.httpclient.MFHttpRespInfo;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.LinkedHashMap;
+import java.util.Map;
+
+import com.miniframe.core.Transmitter;
+import com.miniframe.core.ext.UtilTools;
+import com.miniframe.generate.comm.es.D_ES0029;
+import com.miniframe.generate.comm.es.D_ESHEAD;
+
+import com.miniframe.generate.business.es.model.ES0029BaseModel;
+
+public class ES0029Client {
+
+	private static final Logger logger = LoggerFactory.getLogger(ES0029Client.class);
+	private MFHttpRespInfo respInfo;
+
+	public MFHttpRespInfo getRespInfo(){
+		return respInfo;
+	}
+
+	/**
+	 * 调用 [无锡发动机->组件复制((ES0029)]的通讯接口
+	 * @param model 接口模型
+	 * @param extMap 扩展输入
+	 * @param url 请求地址
+	 * @return model 接口模型
+	 * @throws Exception
+	 */
+	@SuppressWarnings({ "rawtypes", "unchecked" })
+	public ES0029BaseModel execute(ES0029BaseModel model,final Map extMap,final String url) throws Exception {
+		this.executeToRespInfo(model,extMap,url);
+		return model;
+	}
+
+	@SuppressWarnings({ "rawtypes", "unchecked" })
+	public ES0029BaseModel execute(ES0029BaseModel model,final Map extMap) throws Exception {
+		this.executeToRespInfo(model,extMap,null);
+		return model;
+	}
+
+
+	@SuppressWarnings({ "rawtypes", "unchecked" })
+	public MFHttpRespInfo executeToRespInfo(ES0029BaseModel model,final Map extMap,final String url) throws Exception {
+		if (logger.isDebugEnabled()) {
+			logger.debug("execute(ES0029BaseModel) - start");
+		}
+
+		if(UtilTools.isNullOrBlank(model.getA_eshead().getTransCode())){
+			model.getA_eshead().setTransCode("ES0029");
+		}
+
+		Map inMap = new LinkedHashMap();
+		inMap.putAll(UtilTools.obj2Map(model.getA_eshead()));
+		inMap.putAll(UtilTools.obj2Map(model.getA_es0029()));
+		if(extMap!=null && extMap.size()>0){
+			inMap.putAll(extMap);
+		}
+
+		Transmitter httpesApater = (Transmitter) UtilTools.getBean("httpesApater");
+		MFHttpRespInfo respInfo;
+		if(UtilTools.isNotNullAndBlank(url)){
+			respInfo = httpesApater.doPostDataToRespInfo(inMap,url);
+		}else{
+			respInfo = httpesApater.doPostDataToRespInfo(inMap);
+		}
+
+		if(respInfo!=null) {
+			Map outMap=respInfo.getParamMap();
+			D_ESHEAD d_eshead =  UtilTools.map2Obj(outMap, D_ESHEAD.class);
+			D_ES0029 d_es0029 =  UtilTools.map2Obj(outMap, D_ES0029.class);
+			model.setD_eshead(d_eshead);
+			model.setD_es0029(d_es0029);
+
+
+		}
+
+		if (logger.isDebugEnabled()) {
+			logger.debug("execute(ES0029BaseModel) - end");
+		}
+
+        this.respInfo=respInfo;
+
+		return respInfo;
+	}
+
+
+
+	@SuppressWarnings({ "rawtypes", "unchecked" })
+	public ES0029BaseModel execute(ES0029BaseModel model) throws Exception {
+		return this.execute(model,null,null);
+	}
+
+
+}

+ 12 - 0
generated/validateform/a_es0029Form.xml

@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE form-validation PUBLIC "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.1//EN" "http://jakarta.apache.org/commons/dtds/validator_1_1.dtd">
+<!-- 组件复制Form配置文件系统生成请勿修改,否则重新生成将覆盖 -->
+<form-validation>
+<formset>
+<form name="a_es0029Form">
+<field property="pid" depends="required">
+    <arg0 key="a_es0029.pid"/>
+</field>
+</form>
+</formset>
+</form-validation>

+ 12 - 0
generated/validateform/d_es0029Form.xml

@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE form-validation PUBLIC "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.1//EN" "http://jakarta.apache.org/commons/dtds/validator_1_1.dtd">
+<!-- 组件复制Form配置文件系统生成请勿修改,否则重新生成将覆盖 -->
+<form-validation>
+<formset>
+<form name="d_es0029Form">
+<field property="cpjson" depends="required">
+    <arg0 key="d_es0029.cpjson"/>
+</field>
+</form>
+</formset>
+</form-validation>

+ 3 - 0
generated/validator/resources_a_es0029Form_validator.properties

@@ -0,0 +1,3 @@
+a_es0029.pid = \u9879\u76EE\u7F16\u7801
+a_es0029.npid = \u76EE\u6807\u9879\u76EE\u7F16\u7801
+a_es0029Form = true

+ 3 - 0
generated/validator/resources_a_es0029Form_validator_zh_CN.properties

@@ -0,0 +1,3 @@
+a_es0029.pid = \u9879\u76EE\u7F16\u7801
+a_es0029.npid = \u76EE\u6807\u9879\u76EE\u7F16\u7801
+a_es0029Form = true

+ 2 - 0
generated/validator/resources_a_es0029_pccids_recodeForm_validator.properties

@@ -0,0 +1,2 @@
+a_es0029_pccids_recode.pccid = \u8FDE\u7EBF\u7F16\u7801
+a_es0029_pccids_recodeForm = true

+ 2 - 0
generated/validator/resources_a_es0029_pccids_recodeForm_validator_zh_CN.properties

@@ -0,0 +1,2 @@
+a_es0029_pccids_recode.pccid = \u8FDE\u7EBF\u7F16\u7801
+a_es0029_pccids_recodeForm = true

+ 2 - 0
generated/validator/resources_a_es0029_pcids_recodeForm_validator.properties

@@ -0,0 +1,2 @@
+a_es0029_pcids_recode.pcid = \u7EC4\u4EF6\u7F16\u7801
+a_es0029_pcids_recodeForm = true

+ 2 - 0
generated/validator/resources_a_es0029_pcids_recodeForm_validator_zh_CN.properties

@@ -0,0 +1,2 @@
+a_es0029_pcids_recode.pcid = \u7EC4\u4EF6\u7F16\u7801
+a_es0029_pcids_recodeForm = true

+ 2 - 0
generated/validator/resources_d_es0029Form_validator.properties

@@ -0,0 +1,2 @@
+d_es0029.cpjson = \u6620\u5C04\u7ED3\u679CJson
+d_es0029Form = true

+ 2 - 0
generated/validator/resources_d_es0029Form_validator_zh_CN.properties

@@ -0,0 +1,2 @@
+d_es0029.cpjson = \u6620\u5C04\u7ED3\u679CJson
+d_es0029Form = true

+ 135 - 0
src/main/java/com/miniframe/bisiness/es/ES0029Service.java

@@ -0,0 +1,135 @@
+package com.miniframe.bisiness.es;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import com.miniframe.core.ExecProcessFlow;
+import com.miniframe.core.ext.UtilTools;
+import com.miniframe.generate.business.es.model.ES0029BaseModel;
+import com.miniframe.generate.comm.es.A_ES0029;
+import com.miniframe.generate.comm.es.A_ES0029_PCCIDS_RECODE;
+import com.miniframe.generate.comm.es.A_ES0029_PCIDS_RECODE;
+import com.miniframe.mappers.es.model.PcCopyVo;
+import com.miniframe.model.es.*;
+import com.miniframe.model.es.dao.EsProComAttDataMapper;
+import com.miniframe.model.es.dao.EsProComAttMapper;
+import com.miniframe.model.es.dao.EsProComConMapper;
+import com.miniframe.model.es.dao.EsProComMapper;
+import com.miniframe.tools.XiJsonUtil;
+
+/**
+ * 无锡发动机,“组件复制”逻辑处理(重新生成不覆盖)。
+ */
+public class ES0029Service extends ES0029BaseModel implements ExecProcessFlow {
+	
+	private static final long serialVersionUID = -7051358269847459502L;
+		
+	/**
+	 * 无锡发动机,“组件复制”业务核心处理
+ 	 */
+	public void transExecute() throws Exception {
+		String pid =this.getA_es0029().getPid();
+		String npid = this.getA_es0029().getNpid();
+		List<A_ES0029_PCIDS_RECODE> pcids=this.getA_es0029().getPcids();
+		List<A_ES0029_PCCIDS_RECODE> pccids=this.getA_es0029().getPccids();
+		//组件复制
+		List<PcCopyVo> vos =new ArrayList<>();
+		Map<String,String> comIdsMap = new HashMap<>();
+		for (A_ES0029_PCIDS_RECODE pcidr:pcids) {
+			String pcid = pcidr.getPcid();
+			EsProComMapper comdao = UtilTools.getBean(EsProComMapper.class);
+			EsProCom com = comdao.selectByPrimaryKey(pcid);
+			if(com==null){
+				continue;
+			}
+			String npcid = UtilTools.getUUid();
+			EsProComAttMapper comattdao = UtilTools.getBean(EsProComAttMapper.class);
+			EsProComAttSQLBuilder comattsb = new EsProComAttSQLBuilder();
+			EsProComAttSQLBuilder.Criteria comattsc = comattsb.createCriteria();
+			comattsc.andPcIdEqualTo(pcid);
+			List<EsProComAtt> atts = comattdao.selectByExample(comattsb);
+			for (EsProComAtt att:atts) {
+				EsProComAttDataMapper comattdatadao = UtilTools.getBean(EsProComAttDataMapper.class);
+				EsProComAttDataSQLBuilder comattdatasb = new EsProComAttDataSQLBuilder();
+				EsProComAttDataSQLBuilder.Criteria comattdatasc = comattdatasb.createCriteria();
+				comattdatasc.andPcaIdEqualTo(att.getPcaId());
+				List<EsProComAttData> attDatas = comattdatadao.selectByExample(comattdatasb);
+				String nPcaId=UtilTools.getUUid();
+				for (EsProComAttData attd:attDatas) {
+					attd.setPcId(npcid);
+					attd.setPcaId(nPcaId);
+					attd.setPcadId(UtilTools.getUUid());
+					attd.setPid(npid);
+					comattdatadao.insert(attd);
+				}
+				att.setPcId(npcid);
+				att.setPcaId(nPcaId);
+				att.setPid(npid);
+				comattdao.insert(att);
+			}
+			com.setPid(npid);
+			com.setPcId(npcid);
+			comdao.insert(com);
+
+			comIdsMap.put(pcid,npcid);
+			PcCopyVo cp= new PcCopyVo();
+			cp.setType(1);
+			cp.setOldId(pcid);
+			cp.setNewId(npcid);
+			vos.add(cp);
+		}
+
+
+		for (A_ES0029_PCCIDS_RECODE pccidr:pccids) {
+			String pccid =pccidr.getPccid();
+			EsProComConMapper condao = UtilTools.getBean(EsProComConMapper.class);
+			EsProComCon con = condao.selectByPrimaryKey(pccid);
+			String npccid =UtilTools.getUUid();
+			con.setPcId(comIdsMap.get(con.getPcId()));
+			con.setNpcId(comIdsMap.get(con.getNpcId()));
+			con.setPccId(npccid);
+			con.setPid(npid);
+			condao.insert(con);
+
+
+			PcCopyVo cp= new PcCopyVo();
+			cp.setType(2);
+			cp.setOldId(pccid);
+			cp.setNewId(npccid);
+			vos.add(cp);
+		}
+		this.getD_es0029().setCpjson(XiJsonUtil.objectToJson(vos));
+	}
+
+
+
+	
+	/**
+	 * 无锡发动机,“组件复制”业务前处理
+ 	 */
+	public void preTransFlow() throws Exception {
+		this.validater();
+	}
+	
+	/**
+	 * 无锡发动机,“组件复制”业务后处理
+ 	 */
+	public void afterTransFlow() throws Exception {
+	
+	}
+	
+	/**
+	 * 无锡发动机,“组件复制”逻辑入口处理方法
+ 	 */
+ 	@SuppressWarnings("rawtypes")
+	@Override
+	public Map execute(Map vars) throws Exception {
+		this.setTransMap(vars);
+		preTransFlow();// 执行业务开始的规则检查和校验
+		transExecute();// 执行核心业务段
+		afterTransFlow();// 执行核心逻辑完成后的收尾逻辑
+		return this.getTransMap();
+	}
+
+}

+ 13 - 0
src/main/java/com/miniframe/mappers/es/model/PcCopyVo.java

@@ -0,0 +1,13 @@
+package com.miniframe.mappers.es.model;
+
+import lombok.Data;
+
+/**
+ *
+ */
+@Data
+public class PcCopyVo {
+    Integer type;
+    String oldId;
+    String newId;
+}

+ 1 - 1
src/test/java/com/miniframe/ApplicationTests.java

@@ -40,7 +40,7 @@ class ApplicationTests {
     }
     @Test
     void pipentXmlTest() throws Exception {
-        String pid ="2d10f389f5c04fa686eac74289180d3d";
+        String pid ="e5abefdfa34b4f4bb64342815968d72b";
         XIFileUtils.mkdir(XIFileUtils.getRootPathStr());
         XIFileUtils.mkdir(XIFileUtils.getRootPathStr()+"/es");
         XIFileUtils.mkdir(XIFileUtils.getRootPathStr()+"/es/"+pid);

+ 6 - 0
src/test/java/com/miniframe/base64Test.java

@@ -66,6 +66,12 @@ public class base64Test {
             fileBase64Mapper.insert(fileBase64);
         }
     }
+
+
+    public static void main(String[] args) throws Exception {
+        String t = convertToBase64("F:\\es\\es-web\\src\\assets\\img\\node.png");
+        System.out.println(t);
+    }
     //转base64
     public static String convertToBase64(String filePath) throws Exception {
         // 读取图片文件字节

+ 44 - 0
src/test/java/com/miniframe/comm/httpesapater/ES0029Test.java

@@ -0,0 +1,44 @@
+package com.miniframe.comm.httpesapater;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import com.miniframe.comm.httpesapater.HttpesapaterUtil;
+import com.miniframe.generate.comm.es.A_ES0029;
+import com.miniframe.generate.comm.httpesapater.ES0029Client;
+import com.miniframe.generate.business.es.model.ES0029BaseModel;
+
+public class ES0029Test {
+
+	private static final Logger logger = LoggerFactory.getLogger(ES0029Test.class);
+
+	/**
+	 * 组件复制,获取报文体
+	 * @return
+	 */
+	public static A_ES0029 getA_es0029() {
+		A_ES0029 a_es0029 = new A_ES0029();
+
+		// ----------以下增加【组件复制】上行体赋值-------------
+
+
+
+		// ---------------------------------------------------
+		return a_es0029;
+	}
+	
+	/**
+	 * 运行客户端测试,组件复制
+	 * 
+	 * @param args
+	 * @throws Exception
+	 */
+	public static void main(String[] args) throws Exception {
+		ES0029BaseModel model = new ES0029BaseModel();
+		model.setA_eshead(HttpesapaterUtil.getA_eshead("ES0029"));
+		model.setA_es0029(ES0029Test.getA_es0029());
+		ES0029Client client = new ES0029Client();
+		logger.error("客户端发送前总线:\r\n"+model);
+		model = client.execute(model);
+		logger.error("客户端发送后总线:\r\n"+model);
+	}
+}

+ 4 - 0
系统设计/系统模块/ES(无锡发动机).csv

@@ -28,6 +28,10 @@
 100026,ES0026,单位系统删除,service,
 100027,ES0027,图片base64编码查询,service
 100028,ES0028,项目克隆,service
+100029,ES0029,组件复制,service,
+
 
 110001,ES1001,组件查询,service,
 110002,BES001,基础字典查询,service,
+
+

+ 7 - 0
系统设计/通信设计/通讯报文/es(无锡发动机)/报文体/ES0029_A(组件复制).csv

@@ -0,0 +1,7 @@
+"序号","英文名称","中文名称","数据类型","默认值","格式化","非空/引用","最小(长度/值)","最大(长度/值)","验证规则","标准数据ID","XML样式","TAG标签","映射/子标签","CDATA"
+1,pid,项目编码,string,,,是,,,,,,,,
+2,pcids,复制的组件,list,,,,,,,,,,,
+2.1,pcid,组件编码,string,,,,,,,,,,,
+3,pccids,复制的连线,list,,,,,,,,,,,
+3.1,pccid,连线编码,string,,,,,,,,,,,
+4,npid,目标项目编码,string,,,,,,,,,,,

+ 2 - 0
系统设计/通信设计/通讯报文/es(无锡发动机)/报文体/ES0029_D(组件复制).csv

@@ -0,0 +1,2 @@
+"序号","英文名称","中文名称","数据类型","默认值","格式化","非空/引用","最小(长度/值)","最大(长度/值)","验证规则","标准数据ID","XML样式","TAG标签","映射/子标签","CDATA"
+1,cpjson,映射结果Json,string,,,是,,,,,,,,