aris导入流程时角色岗位处理,另角色图增加"岗位文本"属性存储岗位
This commit is contained in:
parent
6e02e23c05
commit
62492a0cee
Binary file not shown.
@ -79,7 +79,7 @@ public class ModelMappingAPIManager {
|
||||
}
|
||||
if (PALMethodCache.getPALMethodModelById("org.normal") != null) {
|
||||
// 角色
|
||||
ObjDefMappingModel o9 = new ObjDefMappingModel("OT_PERS_TYPE", "ST_EMPL_TYPE", "role", "org.normal", null, "shape");
|
||||
ObjDefMappingModel o9 = new ObjDefMappingModel("OT_PERS_TYPE", "ST_EMPL_TYPE", "role", "org.role", null, "shape");
|
||||
objDefMappingMap.put("OT_PERS_TYPE-ST_EMPL_TYPE", o9);
|
||||
// ObjDefMappingModel o9 = new ObjDefMappingModel("OT_PERS_TYPE", "ST_EMPL_TYPE", null, null, "ROLE", "shape");
|
||||
|
||||
@ -92,11 +92,6 @@ public class ModelMappingAPIManager {
|
||||
ObjDefMappingModel o11 = new ObjDefMappingModel("OT_APPL_SYS_TYPE","ST_APPL_SYS_TYPE","appSystem","itsystem.normal",null,"shape");
|
||||
objDefMappingMap.put("OT_APPL_SYS_TYPE-ST_APPL_SYS_TYPE",o11);
|
||||
}
|
||||
if (1==2) {
|
||||
|
||||
|
||||
}
|
||||
|
||||
return objDefMappingMap;
|
||||
}
|
||||
|
||||
|
||||
@ -10,6 +10,7 @@ public class CxnOccModel {
|
||||
|
||||
private String id;// ObjOcc.ID
|
||||
private String toId;// ToObjOcc.IdRef
|
||||
private String modelId;// 所在的模型Id
|
||||
private List<PositionModel> positionList;// 连线起始端+折点
|
||||
|
||||
public String getId() {
|
||||
@ -36,4 +37,11 @@ public class CxnOccModel {
|
||||
this.positionList = positionList;
|
||||
}
|
||||
|
||||
public String getModelId() {
|
||||
return modelId;
|
||||
}
|
||||
|
||||
public void setModelId(String modelId) {
|
||||
this.modelId = modelId;
|
||||
}
|
||||
}
|
||||
|
||||
@ -11,6 +11,7 @@ public class ObjDefModel {
|
||||
private String name;
|
||||
private String typeNum;// 类型1
|
||||
private String symbolNum;// 类型2
|
||||
private String linkedModelIds;// 形状定义连接的modelId,暂时只知道是单个,例如角色链接角色图
|
||||
private JSONObject attrData;// 名称以外的属性存储
|
||||
|
||||
public ObjDefModel() {
|
||||
@ -56,6 +57,14 @@ public class ObjDefModel {
|
||||
this.attrData = attrData;
|
||||
}
|
||||
|
||||
public String getLinkedModelIds() {
|
||||
return linkedModelIds;
|
||||
}
|
||||
|
||||
public void setLinkedModelIds(String linkedModelIds) {
|
||||
this.linkedModelIds = linkedModelIds;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ObjDefModel{" +
|
||||
@ -63,6 +72,7 @@ public class ObjDefModel {
|
||||
", name='" + name + '\'' +
|
||||
", typeNum='" + typeNum + '\'' +
|
||||
", symbolNum='" + symbolNum + '\'' +
|
||||
", linkedModelIds='" + linkedModelIds + '\'' +
|
||||
", attrData=" + attrData +
|
||||
'}';
|
||||
}
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package com.actionsoft.apps.coe.pal.datamigration.aris.web;
|
||||
|
||||
import com.actionsoft.apps.coe.pal.datamigration.aris.mapping.ModelMappingAPIManager;
|
||||
import com.actionsoft.apps.coe.pal.datamigration.aris.model.*;
|
||||
import com.actionsoft.bpms.util.UtilString;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
@ -24,7 +25,7 @@ public class ArisXmlHandleWeb {
|
||||
|
||||
public Map<String, ObjOccModel> objOccMap = new HashMap<>();// 所有模型中所有形状map记录
|
||||
|
||||
public Map<String, List<CxnOccModel>> cxnOccMap = new HashMap<>();// 所有模型中所有连线map记录
|
||||
public Map<String, List<CxnOccModel>> cxnOccMap = new HashMap<>();// 所有模型中所有连线map记录(所有出现的连线)
|
||||
|
||||
public Map<String, Set<String>> objDefLinkerMap = new HashMap<>();// 记录所有定义形状的连线map记录
|
||||
|
||||
@ -43,7 +44,7 @@ public class ArisXmlHandleWeb {
|
||||
calculateModelPath();
|
||||
// 计算定义形状之间的连线
|
||||
calculateObjDefLinker();
|
||||
// test();
|
||||
test();
|
||||
}
|
||||
|
||||
/**
|
||||
@ -178,11 +179,13 @@ public class ArisXmlHandleWeb {
|
||||
String id = e.attributeValue("ObjDef.ID");
|
||||
String typeNum = e.attributeValue("TypeNum");
|
||||
String symbolNum = e.attributeValue("SymbolNum");
|
||||
String linkedModelIds = e.attributeValue("LinkedModels.IdRefs");
|
||||
ObjDefModel objDefModel = new ObjDefModel();
|
||||
objDefModel.setId(id);
|
||||
objDefModel.setName(name);
|
||||
objDefModel.setTypeNum(typeNum);
|
||||
objDefModel.setSymbolNum(symbolNum);
|
||||
objDefModel.setLinkedModelIds(linkedModelIds);
|
||||
objDefModel.setAttrData(objDefAttr);
|
||||
objDefMap.put(id, objDefModel);
|
||||
continue;// 不再往下遍历
|
||||
@ -240,7 +243,7 @@ public class ArisXmlHandleWeb {
|
||||
objOccModel.setSymbolNum(e.attributeValue("SymbolNum"));
|
||||
objOccMap.put(id, objOccModel);
|
||||
// 连线处理
|
||||
getCxnOccModel(id, e);
|
||||
getCxnOccModel(id, e, modelId);
|
||||
|
||||
|
||||
if (!modelObjOccMap.containsKey(modelId)) {
|
||||
@ -254,7 +257,7 @@ public class ArisXmlHandleWeb {
|
||||
}
|
||||
|
||||
// 计算连线,创建连线对象
|
||||
private void getCxnOccModel(String id, Element e) {
|
||||
private void getCxnOccModel(String id, Element e, String modelId) {
|
||||
List<Element> list = e.elements("CxnOcc");
|
||||
if (list != null && list.size() > 0) {
|
||||
for (Element cxnEle: list) {
|
||||
@ -264,6 +267,7 @@ public class ArisXmlHandleWeb {
|
||||
CxnOccModel cxnOccModel = new CxnOccModel();
|
||||
cxnOccModel.setId(id);
|
||||
cxnOccModel.setToId(toId);
|
||||
cxnOccModel.setModelId(modelId);
|
||||
cxnOccModel.setPositionList(new ArrayList<>());
|
||||
for (Element posEle: posList) {
|
||||
int x = Integer.parseInt(posEle.attributeValue("Pos.X")) / 3;
|
||||
@ -292,14 +296,24 @@ public class ArisXmlHandleWeb {
|
||||
if (list != null) {
|
||||
System.out.println("模型内形状信息:");
|
||||
for (ObjOccModel objOccModel : list) {
|
||||
System.out.println("模型内的形状信息:" + objDefMap.get(objOccModel.getDefId()).getName());
|
||||
ObjDefModel o = objDefMap.get(objOccModel.getDefId());
|
||||
if (o.getName().equals("物流系统各单位计划专员") || o.getName().equals("物流计划专员")) {
|
||||
System.out.println("xxxxx");
|
||||
}
|
||||
String type1 = (o.getTypeNum().equals("OT_PERS_TYPE") && o.getSymbolNum().equals("ST_EMPL_TYPE")) ? "角色":
|
||||
(o.getTypeNum().equals("OT_POS") && o.getSymbolNum().equals("ST_POS")) ? "岗位" : "无";
|
||||
System.out.println("模型内的形状信息:" + "【" + type1 + "】" + objDefMap.get(objOccModel.getDefId()).getName());
|
||||
System.out.println("该形状定义信息的下一个连线定义形状:");
|
||||
Set<String> set = objDefLinkerMap.get(objOccModel.getDefId());
|
||||
if (set.size() == 0) {
|
||||
System.out.println("无");
|
||||
} else {
|
||||
for (String defId : set) {
|
||||
System.out.println(objDefMap.get(defId).getName());
|
||||
ModelMappingAPIManager.getInstance().getObjDefMappingMap().get(objDefMap.get(defId).getSymbolNum() + "-" + objDefMap.get(defId).getTypeNum());
|
||||
ObjDefModel def = objDefMap.get(defId);
|
||||
String type = (def.getTypeNum().equals("OT_PERS_TYPE") && def.getSymbolNum().equals("ST_EMPL_TYPE")) ? "角色":
|
||||
(def.getTypeNum().equals("OT_POS") && def.getSymbolNum().equals("ST_POS")) ? "岗位" : "无";
|
||||
System.out.println("【" + type + "】" + objDefMap.get(defId).getName());
|
||||
}
|
||||
}
|
||||
System.out.println("-------------");
|
||||
|
||||
@ -32,6 +32,9 @@ public class Constant {
|
||||
// public static final String METHOD_POST = "post";
|
||||
public static final String METHOD_POST = "post";
|
||||
|
||||
// 岗位的文本属性,后期转换为关联属性
|
||||
public static final String METHOD_POST_TEXT = "post_text";
|
||||
|
||||
// 建模属性代码--信息系统
|
||||
public static final String METHOD_INFO_SYSTEM = "information_systems";
|
||||
|
||||
|
||||
@ -56,6 +56,7 @@ import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.dom4j.Document;
|
||||
import org.dom4j.Entity;
|
||||
|
||||
import java.io.File;
|
||||
import java.text.ParseException;
|
||||
@ -138,8 +139,8 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
String number = this.checkMethodInfo(wsId, "process.epc", "process", "process.epc", "过程链图", "编号", Constant.METHOD_NUMBER);
|
||||
if (UtilString.isNotEmpty(number)) return ResponseObject.newWarnResponse(number).toString();
|
||||
// 校验角色图下是否有建模属性【岗位】
|
||||
String post = this.checkMethodInfo(wsId, "org.normal", "org", "org.normal", "角色图", "岗位", Constant.METHOD_POST);
|
||||
if (UtilString.isNotEmpty(post)) return ResponseObject.newWarnResponse(post).toString();
|
||||
// String post = this.checkMethodInfo(wsId, "org.normal", "org", "org.normal", "角色图", "岗位", Constant.METHOD_POST);
|
||||
// if (UtilString.isNotEmpty(post)) return ResponseObject.newWarnResponse(post).toString();
|
||||
// 校验过程链图下是否有建模属性【角色】
|
||||
String role = this.checkMethodInfo(wsId, "process.epc", "process", "process.epc", "过程链图", "角色", Constant.METHOD_ROLE);
|
||||
if (UtilString.isNotEmpty(role)) return ResponseObject.newWarnResponse(role).toString();
|
||||
@ -178,8 +179,8 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
// String fileName = "xmlexport.xml";
|
||||
// 读取xml文件
|
||||
Document d = XMLUtil.readXML(file.getPath(), true);
|
||||
// String toFilePath = "/Users/sunlh/Documents/ideaData/actionsoft/aws6.4.1.1008.yili2/apps/com.actionsoft.apps.coe.pal.datamigration/testFile/targetFile/";
|
||||
// XMLUtil.writeXml(d, toFilePath + fileName);
|
||||
String toFilePath = "/Users/sunlh/Documents/ideaData/actionsoft/aws6.4.1.1008.yili2/apps/com.actionsoft.apps.coe.pal.datamigration/testFile/targetFile/";
|
||||
XMLUtil.writeXml(d, toFilePath + fileName);
|
||||
// 解析xml文件
|
||||
if (d == null) {
|
||||
return ResponseObject.newErrResponse().toString();
|
||||
@ -221,15 +222,24 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
}
|
||||
}
|
||||
|
||||
PALRepository coeProcessLevel = CoeProcessLevelDaoFacotory.createCoeProcessLevel();
|
||||
|
||||
// 存储匹配到与未匹配到的模型信息
|
||||
List<ModelModel> matchModels = new ArrayList<>();
|
||||
List<ModelModel> unMatchModels = new ArrayList<>();
|
||||
// 存储已经匹配上但是文件里已经有内容【可能导入重复】的模型信息
|
||||
List<ModelModel> repeatModels = new ArrayList<>();
|
||||
// 存储不包含图形的流程
|
||||
// 存储不包含图形的流程,无任何形状的流程不进行导入
|
||||
List<ModelModel> currentModelNoShape = new ArrayList<>();
|
||||
for (Map.Entry<String, ModelModel> entry : modelMap.entrySet()) {
|
||||
ModelModel arisModel = entry.getValue();
|
||||
// 创建角色模型
|
||||
List<ObjOccModel> objOccModels = modelObjOccMap.get(arisModel.getId());
|
||||
if (objOccModels == null || objOccModels.size() == 0) {
|
||||
currentModelNoShape.add(arisModel);
|
||||
printMsg("流程" + arisModel.getName() + arisModel.getId() + "无任何模型,导入忽略");
|
||||
continue;
|
||||
}
|
||||
// 匹配模型
|
||||
PALRepositoryModel palModel = matchPalModel(arisModel, wsId);
|
||||
if (palModel != null) {
|
||||
@ -241,61 +251,30 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
defineModel = CoeDesignerUtil.createModel(plId, 0);
|
||||
defineModel.setCreateHistory(false);
|
||||
}
|
||||
defineModel.setUpdateTime(new SimpleDateFormat(CoeDesignerConstant.DATE_TIME_STYLE_YYYY_MM_DD_HH_MM_SS).format(new Date()));
|
||||
String timestamp = new SimpleDateFormat(CoeDesignerConstant.DATE_TIME_STYLE_YYYY_MM_DD_HH_MM_SS).format(new Date());
|
||||
defineModel.setUpdateTime(timestamp);
|
||||
String define = defineModel.getDefinition();
|
||||
JSONObject definition = JSONObject.parseObject(define);
|
||||
JSONObject elements = definition.getJSONObject("elements");
|
||||
if (elements != null && !elements.isEmpty()) {
|
||||
// 导入模型已存在数据,不允许导入 todo
|
||||
repeatModels.add(arisModel);
|
||||
printMsg("[" + arisModel.getName() + "] 导入模型已存在数据,不允许导入");
|
||||
printMsg("[" + arisModel.getName() + "] 导入流程模型已存在数据,不允许导入,对同名角色模型进行忽略处理");
|
||||
continue;
|
||||
}
|
||||
|
||||
// 组织下创建【角色模型】文件夹
|
||||
List<PALRepositoryModel> defaultModels = PALRepositoryQueryAPIManager.getInstance().getPalRepositoryModelsByWsIdAndMethodId(wsId, "org");
|
||||
defaultModels = defaultModels.stream()
|
||||
.filter(model -> "default".equals(model.getMethodId()))
|
||||
.filter(model -> Constant.DEFAULT_FOLDER_NAME.equals(model.getName())).collect(Collectors.toList());
|
||||
if (defaultModels.size() == 0) {
|
||||
String id = UUIDGener.getUUID();
|
||||
String id2 = UUIDGener.getUUID();
|
||||
|
||||
String plRid = UUIDGener.getUUID();
|
||||
String plRid2 = UUIDGener.getUUID();
|
||||
PALRepository coeProcessLevel = CoeProcessLevelDaoFacotory.createCoeProcessLevel();
|
||||
int orderIndex = coeProcessLevel.getChildrenMaxOrderIndexByPidAndWsId("org", wsId) + 1;
|
||||
Timestamp nowTime = new Timestamp(System.currentTimeMillis());
|
||||
PALRepositoryModelImpl defaultModel = CoeProcessLevelUtil.createPALRepositoryModel(id, plRid, wsId, Constant.DEFAULT_FOLDER_NAME, "", orderIndex, "org", "org", true, 1,
|
||||
id, false, "default", "0", 1, null, null, _uc.getUID(), _uc.getUID(), nowTime, null, null, null, null,
|
||||
null, null, null, null, null, -1);
|
||||
coeProcessLevel.insert(defaultModel);
|
||||
defaultModels.add(defaultModel);
|
||||
PALRepositoryModelImpl defaultModel2 = CoeProcessLevelUtil.createPALRepositoryModel(id2, plRid2, wsId, "岗位模型", "", orderIndex, "org", "org", true, 1,
|
||||
id, false, "default", "0", 1, null, null, _uc.getUID(), _uc.getUID(), nowTime, null, null, null, null,
|
||||
null, null, null, null, null, -1);
|
||||
coeProcessLevel.insert(defaultModel2);
|
||||
defaultModels.add(defaultModel2);
|
||||
printMsg("角色模型文件夹创建成功 " + defaultModel.getId());
|
||||
}
|
||||
PALRepositoryModel defaultModel = defaultModels.get(0);
|
||||
if (defaultModel == null) printMsg("角色模型文件夹创建失败");
|
||||
PALRepositoryModel defaultModel2 = defaultModels.get(0);
|
||||
if (defaultModel == null) printMsg("岗位模型文件夹创建失败");
|
||||
|
||||
// 处理岗位信息
|
||||
//【需求概要】只将当前流程下所关联的角色所关联的岗位信息转换成PAL存储的格式 并保存一份映射关系方便后续处理
|
||||
Map<String, JSONObject> positionShapeIdRelationMap = new HashMap<>();
|
||||
this.handlePositionShape(defaultModel2.getId(), wsId, currentModelNoShape, positionShapeIdRelationMap, arisModel, modelObjOccMap, objDefMap);
|
||||
|
||||
// 生成当前流程下角色图 并将岗位信息作为活动属性与之关联
|
||||
Map<String, JSONObject> roleShapeIdRelationMap = new HashMap<>();
|
||||
this.handleRoleShape(wsId, currentModelNoShape, defaultModel.getId(), positionShapeIdRelationMap, roleShapeIdRelationMap, arisModel, modelObjOccMap, objDefMap, cxnOccMap);
|
||||
String rolefolderId = checkAndCreatePalRoleFolderModel(coeProcessLevel, wsId);// 创建/获取角色文件夹ID,作为角色的顶级文件夹
|
||||
Map<String, String> arisFunIdRelationPalRoleMap = new HashMap<>();// aris功能模型与aris角色模型的id映射,key:aris fun shape id,value:pal role id
|
||||
Map<String, String> palRoleIdRelationNameMap = new HashMap<>();// key pal role shape id ,value:pal role shape text
|
||||
// 创建角色模型和角色元素,并且获取aris角色与pal角色映射关系
|
||||
String roleMdoelId = createRoleModelAndElements(coeProcessLevel, rolefolderId, wsId, currentModelNoShape, palModel, arisModel, modelObjOccMap, objDefMap, objOccMap, cxnOccMap, objDefLinkerMap, arisFunIdRelationPalRoleMap, methodAttrsMap, palRoleIdRelationNameMap);
|
||||
|
||||
// 存储当前模型下ARIS图形ID与PAL图形ID映射关系
|
||||
Map<String, String> idRelationMap = new HashMap<>();
|
||||
|
||||
Map<String, String> palShapeIdRelationArisOccIdMap = new HashMap<>();
|
||||
// 创建形状和连线
|
||||
JSONObject newElements = createShapeElement(wsId, currentModelNoShape, idRelationMap, roleShapeIdRelationMap, palModel, arisModel, modelObjOccMap, objDefMap, objOccMap, cxnOccMap);
|
||||
JSONObject newElements = createShapeElement(wsId, idRelationMap, palModel, arisModel, modelObjOccMap, objDefMap, objOccMap, cxnOccMap, palShapeIdRelationArisOccIdMap);
|
||||
|
||||
if (newElements == null) continue;
|
||||
|
||||
@ -303,7 +282,7 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
this.handleShapeInputOutAttr(wsId, idRelationMap, newElements, arisModel, modelObjOccMap, objDefMap);
|
||||
|
||||
// 处理角色属性与流程相应的活动节点关联
|
||||
this.handleProcessAttrRoleRelation(wsId, palModel.getId(), roleShapeIdRelationMap, newElements, arisModel, modelObjOccMap, objDefMap);
|
||||
this.handleProcessAttrRoleRelation(wsId, palModel.getId(), arisFunIdRelationPalRoleMap, palShapeIdRelationArisOccIdMap, newElements, arisModel, modelObjOccMap, objDefMap, roleMdoelId, palRoleIdRelationNameMap);
|
||||
|
||||
// 处理流程关联属性IT系统
|
||||
this.handleProcessAttrItSystemRelation(wsId, idRelationMap, palModel.getId(), newElements, arisModel, modelObjOccMap, objDefMap, objDefLinkerMap, itShapeMap);
|
||||
@ -333,6 +312,239 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
return ro.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建角色模型和角色元素,并且获取aris角色与pal角色映射关系
|
||||
* 角色与流程活动都是以角色为起点连接流程活动
|
||||
* 角色与岗位都是以岗位为起点连接角色
|
||||
* 活动与角色是1对1关系,不存在单活动对应多个角色
|
||||
* @param coeProcessLevel
|
||||
* @param parentId
|
||||
* @param wsId
|
||||
* @param currentModelNoShape
|
||||
* @param palModel
|
||||
* @param arisModel
|
||||
* @param modelObjOccMap
|
||||
* @param objDefMap
|
||||
* @param objOccMap
|
||||
* @param cxnOccMap
|
||||
* @param objDefLinkerMap
|
||||
* @param arisFunIdRelationPalRoleMap
|
||||
* @param methodAttrsMap
|
||||
* @return
|
||||
*/
|
||||
private String createRoleModelAndElements(PALRepository coeProcessLevel, String parentId, String wsId, List<ModelModel> currentModelNoShape, PALRepositoryModel palModel, ModelModel arisModel, Map<String, List<ObjOccModel>> modelObjOccMap, Map<String, ObjDefModel> objDefMap, Map<String, ObjOccModel> objOccMap, Map<String, List<CxnOccModel>> cxnOccMap, Map<String, Set<String>> objDefLinkerMap, Map<String, String> arisFunIdRelationPalRoleMap, Map<String, Map<String, JSONObject>> methodAttrsMap, Map<String, String> palRoleIdRelationNameMap) {
|
||||
// 统计模型内的角色信息,创建角色与形状的关联关系,提前创建活动与角色的id关联关系,建立角色的角色图,角色图中处理岗位为文本属性内容
|
||||
|
||||
// 统计模型内所有的角色形状
|
||||
List<ObjOccModel> objOccModels = modelObjOccMap.get(arisModel.getId());
|
||||
// 获取角色
|
||||
List<ObjOccModel> roleObjOccModels = new ArrayList<>();
|
||||
for (ObjOccModel objOccModel : objOccModels) {
|
||||
ObjDefModel objDefModel = objDefMap.get(objOccModel.getDefId());
|
||||
if (objDefModel.getTypeNum().equals("OT_PERS_TYPE") && objDefModel.getSymbolNum().equals("ST_EMPL_TYPE")) {// 角色
|
||||
roleObjOccModels.add(objOccModel);
|
||||
}
|
||||
}
|
||||
if (roleObjOccModels.size() == 0) {
|
||||
printMsg("流程模型" + palModel.getName() + "无任何角色模型,忽略角色与岗位导入");
|
||||
return null;
|
||||
}
|
||||
// 创建角色与形状关联关系
|
||||
// 获取当前aris模型内的所有角色list
|
||||
List<CxnOccModel> roleCxnOccModels = new ArrayList<>();
|
||||
for (ObjOccModel roleOccModel : roleObjOccModels) {
|
||||
List<CxnOccModel> list = cxnOccMap.get(roleOccModel.getId());
|
||||
for (CxnOccModel cxnOccModel : list) {
|
||||
if (cxnOccModel.getModelId().equals(arisModel.getId())) {
|
||||
roleCxnOccModels.add(cxnOccModel);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (roleCxnOccModels.size() == 0) {
|
||||
printMsg("流程模型" + palModel.getName() + "无任何角色模型与流程活动进行连接,忽略角色与岗位导入");
|
||||
return null;
|
||||
}
|
||||
|
||||
// 记录重复的角色,根据名称进行记录
|
||||
Map<String, Set<String>> repeatRoleMap = new HashMap<>();
|
||||
// 记录aris功能活动与角色的关系
|
||||
Map<String, String> arisFunRelationRoleMap = new HashMap<>();
|
||||
// 记录重复的角色名称
|
||||
for (CxnOccModel cxnOccModel: roleCxnOccModels) {
|
||||
ObjOccModel occModel = objOccMap.get(cxnOccModel.getId());
|
||||
ObjDefModel objDefModel = objDefMap.get(occModel.getDefId());
|
||||
arisFunRelationRoleMap.put(cxnOccModel.getToId(), objDefModel.getName());
|
||||
String roleName = objDefModel.getName();
|
||||
if (!repeatRoleMap.containsKey(roleName)) {
|
||||
repeatRoleMap.put(roleName, new HashSet<>());
|
||||
}
|
||||
repeatRoleMap.get(roleName).add(occModel.getId());
|
||||
}
|
||||
|
||||
// 创建角色图的名称与PAL角色图形状ID对应关系
|
||||
Map<String, String> roleNamePalIdMap = new HashMap<>();
|
||||
for (String roleName : repeatRoleMap.keySet()) {
|
||||
String roleShapeId = UUIDGener.getObjectId();
|
||||
roleNamePalIdMap.put(roleName, roleShapeId);
|
||||
palRoleIdRelationNameMap.put(roleShapeId, roleName);
|
||||
}
|
||||
// 记录Aris功能Occ ID与PALroleId关联关系
|
||||
for (Map.Entry<String, String> entry : arisFunRelationRoleMap.entrySet()) {
|
||||
if (roleNamePalIdMap.containsKey(entry.getValue())) {
|
||||
arisFunIdRelationPalRoleMap.put(entry.getKey(), roleNamePalIdMap.get(entry.getValue()));
|
||||
}
|
||||
}
|
||||
|
||||
// 角色名称与岗位名称合集
|
||||
Map<String, Set<String>> roleRelationPositonMap = new HashMap<>();
|
||||
// 查找角色对应的岗位
|
||||
for (ObjOccModel roleOccModel : roleObjOccModels) {
|
||||
ObjDefModel roleObjDefModel = objDefMap.get(roleOccModel.getDefId());
|
||||
String linkedModelIds = roleObjDefModel.getLinkedModelIds();
|
||||
if (UtilString.isEmpty(linkedModelIds)) {// 角色无关联角色图
|
||||
printMsg("流程模型" + palModel.getName() + roleObjDefModel.getName() + "角色无任何关联岗位,忽略该角色岗位");
|
||||
} else {// 角色有关联角色图
|
||||
List<ObjOccModel> relationPositonList = modelObjOccMap.get(linkedModelIds);// linkedModelIds按照单个值对待,暂无发现多值
|
||||
if (relationPositonList == null || relationPositonList.size() == 0) {// 角色有关联图但是关联的角色图查询不到
|
||||
printMsg("流程模型" + palModel.getName() + roleObjDefModel.getName() + "角色存在关联LinkedModels.IdRefs:" + linkedModelIds + " 但无法查询对应Model内容");
|
||||
} else {
|
||||
for (ObjOccModel objOccModel: relationPositonList) {
|
||||
ObjDefModel positionDefModel = objDefMap.get(objOccModel.getDefId());
|
||||
if (positionDefModel.getTypeNum().equals("OT_POS") && positionDefModel.getSymbolNum().equals("ST_POS")) {
|
||||
// 查询出岗位,记录到角色中,角色名称为key,岗位名称为value
|
||||
if (!roleRelationPositonMap.containsKey(roleObjDefModel.getName())) {
|
||||
roleRelationPositonMap.put(roleObjDefModel.getName(), new HashSet<>());
|
||||
}
|
||||
roleRelationPositonMap.get(roleObjDefModel.getName()).add(positionDefModel.getName());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 生成一个空的与流程同名角色模型文件
|
||||
String id = UUIDGener.getUUID();
|
||||
int orderIndex = coeProcessLevel.getChildrenMaxOrderIndexByPidAndWsId(parentId, wsId) + 1;
|
||||
Timestamp nowTime = new Timestamp(System.currentTimeMillis());
|
||||
|
||||
PALRepositoryModelImpl model = CoeProcessLevelUtil.createPALRepositoryModel(id, UUIDGener.getUUID(), wsId, arisModel.getName(), "", orderIndex, parentId, "org", true, 1,
|
||||
id, false, "org.role", "0", 1, null, null, _uc.getUID(), _uc.getUID(), nowTime, null, null, null, null,
|
||||
null, null, null, null, null, -1);
|
||||
coeProcessLevel.insert(model);
|
||||
printMsg("与流程同名的角色空模型创建完成【文件ID】" + model.getId());
|
||||
BaseModel baseModel = CoeDesignerAPIManager.getInstance().getDefinition(model.getId(), 0);
|
||||
if (baseModel == null) {
|
||||
baseModel = CoeDesignerUtil.createModel(model.getId(), 0);
|
||||
baseModel.setCreateHistory(false);
|
||||
}
|
||||
baseModel.setUpdateTime(new SimpleDateFormat(CoeDesignerConstant.DATE_TIME_STYLE_YYYY_MM_DD_HH_MM_SS).format(new Date()));
|
||||
String define = baseModel.getDefinition();
|
||||
JSONObject definition = JSONObject.parseObject(define);
|
||||
JSONObject elements = definition.getJSONObject("elements");
|
||||
Map<String, ObjDefMappingModel> objDefMappingMap = ModelMappingAPIManager.getInstance().getObjDefMappingMap();
|
||||
ObjDefMappingModel objDefMappingModel = objDefMappingMap.get("OT_PERS_TYPE-ST_EMPL_TYPE");
|
||||
String shapeMethodId = objDefMappingModel.getShapeMethod();
|
||||
String shapeType = objDefMappingModel.getShapeType();
|
||||
JSONObject shapeDefine = ShapeUtil.getProcessShapeDefinitionByName(shapeMethodId, shapeType);
|
||||
|
||||
JSONArray shapes = new JSONArray();
|
||||
for (Map.Entry<String, String> entry: roleNamePalIdMap.entrySet()) {
|
||||
String shapeText = entry.getKey();
|
||||
String shapeId = entry.getValue();
|
||||
JSONObject newShape = JSONObject.parseObject(shapeDefine.toString());
|
||||
newShape.put("id", shapeId);
|
||||
newShape.put("text", shapeText);
|
||||
shapes.add(newShape);
|
||||
}
|
||||
|
||||
JSONArray newShapes = this.getMethodElementsJSONArray(shapes, 6);
|
||||
for (int i = 0; i < newShapes.size(); i++) {
|
||||
JSONObject shapeObj = newShapes.getJSONObject(i);
|
||||
elements.put(shapeObj.getString("id"), shapeObj);
|
||||
printMsg("生成角色图 角色【" + shapeObj.getString("text") + "】");
|
||||
}
|
||||
|
||||
// 设置角色图形状默认属性配置
|
||||
this.handleShapeDefaultAttr(wsId, palModel, elements, methodAttrsMap);
|
||||
|
||||
// 完善岗位属性
|
||||
for (String key : elements.keySet()) {
|
||||
JSONObject shape = elements.getJSONObject(key);
|
||||
if ("linker".equals(shape.getString("name"))) {
|
||||
continue;
|
||||
}
|
||||
String shapeText = shape.getString("text");
|
||||
if (roleRelationPositonMap.containsKey(shapeText) && roleRelationPositonMap.get(shapeText).size() > 0) {
|
||||
Set<String> postText = roleRelationPositonMap.get(shapeText);
|
||||
List<String> list = new ArrayList<>(postText);
|
||||
Collections.sort(list);
|
||||
String postTextVal = StringUtils.join(list, ",");// 岗位内容
|
||||
JSONArray dataAttributes = shape.getJSONArray("dataAttributes");
|
||||
if (!dataAttributes.isEmpty() && dataAttributes.size() > 0) {
|
||||
for (Object attribute : dataAttributes) {
|
||||
JSONObject obj = (JSONObject) attribute;
|
||||
if (obj.containsKey("attributesJsonArray")) {
|
||||
JSONArray attributesJsonArray = obj.getJSONArray("attributesJsonArray");
|
||||
boolean flag = false;
|
||||
for (int i = 0; i < attributesJsonArray.size(); i++) {
|
||||
if (attributesJsonArray.getJSONObject(i).containsKey("id")) {
|
||||
String attrId = Constant.METHOD_POST_TEXT;
|
||||
if (attrId.equals(attributesJsonArray.getJSONObject(i).getString("id"))) {
|
||||
flag = true;
|
||||
attributesJsonArray.getJSONObject(i).put("value", postTextVal);
|
||||
printMsg("角色图" + model.getName() + "角色" + shapeText + "岗位属性值为" + postTextVal);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!flag) {
|
||||
printMsg("角色图" + model.getName() + "角色" + shapeText + "没有岗位属性配置" + Constant.METHOD_POST_TEXT);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
printMsg("角色图" + model.getName() + "角色" + shapeText + "无岗位属性内容值");
|
||||
}
|
||||
}
|
||||
definition.put("elements", elements);
|
||||
// 设置画布大小
|
||||
setDiagramHeightWidth(definition, elements);
|
||||
baseModel.setDefinition(definition.toString());
|
||||
// 保存文件
|
||||
CoeDesignerAPIManager.getInstance().storeDefinition(baseModel);// dao操作
|
||||
return id;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验和创建角色模型文件夹
|
||||
* @param coeProcessLevel
|
||||
* @param wsId
|
||||
* @return 已经存在的或新创建的角色模型ID
|
||||
*/
|
||||
private String checkAndCreatePalRoleFolderModel(PALRepository coeProcessLevel, String wsId) {
|
||||
// 组织下创建【角色模型】文件夹
|
||||
List<PALRepositoryModel> defaultModels = PALRepositoryQueryAPIManager.getInstance().getPalRepositoryModelsByWsIdAndMethodId(wsId, "org");
|
||||
defaultModels = defaultModels.stream()
|
||||
.filter(model -> "default".equals(model.getMethodId()))
|
||||
.filter(model -> Constant.DEFAULT_FOLDER_NAME.equals(model.getName())).collect(Collectors.toList());
|
||||
if (defaultModels.size() == 0) {
|
||||
String id = UUIDGener.getUUID();
|
||||
|
||||
int orderIndex = coeProcessLevel.getChildrenMaxOrderIndexByPidAndWsId("org", wsId) + 1;
|
||||
Timestamp nowTime = new Timestamp(System.currentTimeMillis());
|
||||
PALRepositoryModelImpl defaultModel = CoeProcessLevelUtil.createPALRepositoryModel(id, UUIDGener.getUUID(), wsId, Constant.DEFAULT_FOLDER_NAME, "", orderIndex, "org", "org", true, 1,
|
||||
id, false, "default", "0", 1, null, null, _uc.getUID(), _uc.getUID(), nowTime, null, null, null, null,
|
||||
null, null, null, null, null, -1);
|
||||
coeProcessLevel.insert(defaultModel);
|
||||
defaultModels.add(defaultModel);
|
||||
printMsg("角色模型文件夹创建成功 " + defaultModel.getId());
|
||||
return defaultModel.getId();
|
||||
} else {
|
||||
printMsg("角色模型文件夹已存在,不再重复创建");
|
||||
return defaultModels.get(0).getId();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 自定义属性
|
||||
* @param wsId
|
||||
@ -483,31 +695,16 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
* @param objDefMap
|
||||
* @return
|
||||
*/
|
||||
private JSONObject createShapeElement(String wsId, List<ModelModel> currentModelNoShape, Map<String, String> idRelationMap, Map<String, JSONObject> roleShapeIdRelationMap, PALRepositoryModel palModel, ModelModel arisModel, Map<String, List<ObjOccModel>> modelObjOccMap, Map<String, ObjDefModel> objDefMap, Map<String, ObjOccModel> objOccMap, Map<String, List<CxnOccModel>> cxnOccMap) {
|
||||
// 存储没有图形的流程
|
||||
private JSONObject createShapeElement(String wsId, Map<String, String> idRelationMap, PALRepositoryModel palModel, ModelModel arisModel, Map<String, List<ObjOccModel>> modelObjOccMap, Map<String, ObjDefModel> objDefMap, Map<String, ObjOccModel> objOccMap, Map<String, List<CxnOccModel>> cxnOccMap, Map<String, String> palShapeIdRelationArisOccIdMap) {
|
||||
// aris中该模型所有形状
|
||||
List<ObjOccModel> objOccModels = modelObjOccMap.get(arisModel.getId());
|
||||
if (objOccModels == null || objOccModels.size() == 0) {
|
||||
currentModelNoShape.add(arisModel);
|
||||
return null;
|
||||
}
|
||||
int zindex = 1;
|
||||
JSONObject elements = new JSONObject();
|
||||
Map<String, ObjDefMappingModel> objDefMappingMap = ModelMappingAPIManager.getInstance().getObjDefMappingMap();
|
||||
ObjDefMappingModel objDefMappingRoleModel = objDefMappingMap.get("OT_PERS_TYPE-ST_EMPL_TYPE");
|
||||
// Map<String, String> idRelationMap = new HashMap<>();
|
||||
for (ObjOccModel objOccModel : objOccModels) {
|
||||
ObjDefModel objDefModel = objDefMap.get(objOccModel.getDefId());// 形状定义
|
||||
if (objDefMappingMap.containsKey(objDefModel.getTypeNum() + "-" + objOccModel.getSymbolNum())) {
|
||||
ObjDefMappingModel objDefMappingModel = objDefMappingMap.get(objDefModel.getTypeNum() + "-" + objOccModel.getSymbolNum());// Aris与PAL形状映射关系
|
||||
|
||||
|
||||
String importType = objDefMappingModel.getMappingType();
|
||||
if ("attr".equals(importType)) {
|
||||
// 该形状导入为一个属性,不在设计器显示,并删除与其相关连线
|
||||
String palShapeAttr = objDefMappingModel.getMappingAttrId();
|
||||
continue;
|
||||
}
|
||||
String shapeMethodId = objDefMappingModel.getShapeMethod();
|
||||
String shapeType = objDefMappingModel.getShapeType();
|
||||
// 伊利导入形状定制
|
||||
@ -516,7 +713,6 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
String arisShapeName = objDefMap.get(objOccModel.getDefId()).getName();
|
||||
String method = shapeMethodId;
|
||||
String shapeName = shapeType;
|
||||
// todo
|
||||
// fun
|
||||
if ("OT_FUNC".equals(symbolNum) && "ST_FUNC".equals(typeNum)) {
|
||||
if (arisShapeName.contains("审批") || arisShapeName.contains("审核")) {
|
||||
@ -534,12 +730,7 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
|
||||
JSONObject shape = ShapeUtil.getProcessShapeDefinitionByName(shapeMethodId, shapeName);
|
||||
String shapeId = UUIDGener.getObjectId();
|
||||
// 复用已经产生的角色图
|
||||
if (objDefModel.getTypeNum().equals(objDefMappingRoleModel.getTypeNum()) && objDefModel.getSymbolNum().equals(objDefMappingRoleModel.getSymbolNum())) {
|
||||
JSONObject roleShapeObj = roleShapeIdRelationMap.get(objOccModel.getId());
|
||||
shapeId = roleShapeObj.getString("shapeId");
|
||||
printMsg("复用已经产生的角色图【ID】 " + shapeId);
|
||||
}
|
||||
palShapeIdRelationArisOccIdMap.put(shapeId, objOccModel.getId());
|
||||
idRelationMap.put(objOccModel.getId(), shapeId);// 记录形状aris形状id与pal形状id
|
||||
shape.put("id", shapeId);
|
||||
// 处理当前图形节点的关联属性【编号】问题
|
||||
@ -967,7 +1158,6 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
Map<String, Set<String>> shapeRelationItMap = new HashMap<>();// 记录PAL形状关联的IT系统文本
|
||||
for (ObjOccModel objOccModel: objOccModels) {
|
||||
String objDefId = objOccModel.getDefId();
|
||||
System.out.println(objDefMap.get(objDefId).getName());
|
||||
// 获取定义形状通过连线进行连接的所有定义形状
|
||||
Set<String> toObjDefIds = objDefLinkerMap.get(objDefId);
|
||||
if (toObjDefIds == null || toObjDefIds.size() == 0) {
|
||||
@ -1002,6 +1192,9 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
m.setRelationShapeText(itShapeMap.get(itShapeName).getString("shapeName"));
|
||||
m.setAttrId(Constant.METHOD_INFO_SYSTEM);
|
||||
relationList.add(m);
|
||||
} else {
|
||||
// todo warn
|
||||
printMsg("流程【" + arisModel.getName() + "】中的活动节点【" + elements.getJSONObject(shapeId).getString("text") + "】未找到IT系统【" + itShapeName + "】");
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1015,18 +1208,20 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
|
||||
/**
|
||||
* 处理关联属性【角色】与流程关联
|
||||
*
|
||||
* @param wsId
|
||||
* @param repositoryModelId
|
||||
* @param roleShapeRelationMap
|
||||
* @param arisFunIdRelationPalRoleMap
|
||||
* @param palShapeIdRelationArisOccIdMap
|
||||
* @param elements
|
||||
* @param arisModel
|
||||
* @param modelObjOccMap
|
||||
* @param objDefMap
|
||||
* @param roleMdoelId
|
||||
* @param palRoleIdRelationNameMap
|
||||
* @throws AWSException
|
||||
*/
|
||||
private void handleProcessAttrRoleRelation(String wsId, String repositoryModelId, Map<String, JSONObject> roleShapeRelationMap, JSONObject elements, ModelModel arisModel,
|
||||
Map<String, List<ObjOccModel>> modelObjOccMap, Map<String, ObjDefModel> objDefMap) throws AWSException {
|
||||
private void handleProcessAttrRoleRelation(String wsId, String repositoryModelId, Map<String, String> arisFunIdRelationPalRoleMap, Map<String, String> palShapeIdRelationArisOccIdMap, JSONObject elements, ModelModel arisModel,
|
||||
Map<String, List<ObjOccModel>> modelObjOccMap, Map<String, ObjDefModel> objDefMap, String roleMdoelId, Map<String, String> palRoleIdRelationNameMap) throws AWSException {
|
||||
// 获取ARIS图形定义与PAL图形定义关系
|
||||
Map<String, ObjDefMappingModel> objDefMappingMap = ModelMappingAPIManager.getInstance().getObjDefMappingMap();
|
||||
ObjDefMappingModel objDefMappingModel = objDefMappingMap.get("OT_PERS_TYPE-ST_EMPL_TYPE");
|
||||
@ -1036,144 +1231,52 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
List<String> removeKey = new ArrayList<>();
|
||||
// 流程关联属性结果集
|
||||
List<DesignerShapeRelationModel> relationList = new ArrayList<>();
|
||||
for (ObjOccModel objOccModel : objOccModels) {
|
||||
ObjDefModel objDefModel = objDefMap.get(objOccModel.getDefId());
|
||||
// 根据ARIS图形定义信息判断当前模型下的所有形状里是否有角色形状
|
||||
if (objDefModel.getTypeNum().equals(objDefMappingModel.getTypeNum()) && objDefModel.getSymbolNum().equals(objDefMappingModel.getSymbolNum())) {
|
||||
JSONObject roleRelationObj = roleShapeRelationMap.get(objOccModel.getId());
|
||||
String roleShapeId = roleRelationObj.getString("shapeId");
|
||||
for (String key : elements.keySet()) {
|
||||
JSONObject tempShapeObj = elements.getJSONObject(key);
|
||||
if ("linker".equals(tempShapeObj.getString("name"))) {
|
||||
if (tempShapeObj.getJSONObject("from").getString("id").equals(roleShapeId)) {
|
||||
List<PALMethodAttributeModel> attributeModels = CoeDesignerShapeAPIManager.getInstance()
|
||||
.getValidAttributeModels(wsId, "process.epc", "process", "process.epc");
|
||||
attributeModels = attributeModels.stream().filter(item -> Constant.METHOD_ROLE.equals(item.getKey())).collect(Collectors.toList());
|
||||
PALMethodAttributeModel attributeModel = attributeModels.get(0);
|
||||
// 将转化后的信息放到相应位置
|
||||
String toShapeId = tempShapeObj.getJSONObject("to").getString("id");
|
||||
DesignerShapeRelationModel relationModel = new DesignerShapeRelationModel();
|
||||
relationModel.setFileId(repositoryModelId);
|
||||
relationModel.setAttrId(attributeModel.getKey());
|
||||
relationModel.setId(UUIDGener.getUUID());
|
||||
relationModel.setShapeId(toShapeId);
|
||||
relationModel.setShapeText(elements.getJSONObject(toShapeId).getString("text"));
|
||||
relationModel.setRelationFileId(roleRelationObj.getString("modelId"));
|
||||
relationModel.setRelationShapeId(roleRelationObj.getString("shapeId"));
|
||||
relationModel.setRelationShapeText(roleRelationObj.getString("shapeText"));
|
||||
relationList.add(relationModel);
|
||||
JSONArray dataAttributes = elements.getJSONObject(toShapeId).getJSONArray("dataAttributes");
|
||||
if (!dataAttributes.isEmpty() && dataAttributes.size() > 0) {
|
||||
JSONObject tempRelationObj = new JSONObject();
|
||||
tempRelationObj.put("value", "");
|
||||
tempRelationObj.put("key", attributeModel.getKey());
|
||||
tempRelationObj.put("isRequired", attributeModel.getIsRequired());
|
||||
tempRelationObj.put("ref", attributeModel.getRef());
|
||||
tempRelationObj.put("readonly", attributeModel.getReadonly());
|
||||
tempRelationObj.put("scope", attributeModel.getScope());
|
||||
tempRelationObj.put("name", attributeModel.getTitle());
|
||||
tempRelationObj.put("id", attributeModel.getKey());
|
||||
tempRelationObj.put("type", attributeModel.getType());
|
||||
tempRelationObj.put("groupPath", attributeModel.getGroupPath());
|
||||
tempRelationObj.put("desc", attributeModel.getDesc());
|
||||
for (Object attribute : dataAttributes) {
|
||||
JSONObject obj = (JSONObject) attribute;
|
||||
if (obj.containsKey("attributesJsonArray")) {
|
||||
JSONArray attributesJsonArray = obj.getJSONArray("attributesJsonArray");
|
||||
JSONArray tempJSONArr = attributesJsonArray.stream()
|
||||
.filter(item -> ((JSONObject) item).getString("key").equals(attributeModel.getKey()))
|
||||
.collect(Collectors.toCollection(JSONArray::new));
|
||||
if (tempJSONArr.size() > 0) {
|
||||
attributesJsonArray.stream().forEach(item -> {
|
||||
if (attributeModel.getKey().equals(((JSONObject) item).getString("key"))) {
|
||||
((JSONObject) item).getJSONArray("value").add(roleShapeId);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
tempRelationObj.put("value", new JSONArray());
|
||||
tempRelationObj.getJSONArray("value").add(roleShapeId);
|
||||
attributesJsonArray.add(tempRelationObj);
|
||||
}
|
||||
break;
|
||||
} else {
|
||||
tempRelationObj.put("value", new JSONArray());
|
||||
tempRelationObj.getJSONArray("value").add(roleShapeId);
|
||||
obj.put("attributesJsonArray", new JSONArray());
|
||||
obj.getJSONArray("attributesJsonArray").add(tempRelationObj);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
// 删除图形与连线
|
||||
removeKey.add(key);
|
||||
removeKey.add(roleShapeId);
|
||||
} else if (tempShapeObj.getJSONObject("to").getString("id").equals(roleShapeId)) {
|
||||
List<PALMethodAttributeModel> attributeModels = CoeDesignerShapeAPIManager.getInstance()
|
||||
.getValidAttributeModels(wsId, "process.epc", "process", "process.epc");
|
||||
attributeModels = attributeModels.stream().filter(item -> Constant.METHOD_ROLE.equals(item.getKey())).collect(Collectors.toList());
|
||||
PALMethodAttributeModel attributeModel = attributeModels.get(0);
|
||||
// 将转化后的信息放到相应位置
|
||||
String toShapeId = tempShapeObj.getJSONObject("from").getString("id");
|
||||
DesignerShapeRelationModel relationModel = new DesignerShapeRelationModel();
|
||||
relationModel.setFileId(repositoryModelId);
|
||||
relationModel.setAttrId(attributeModel.getKey());
|
||||
relationModel.setId(UUIDGener.getUUID());
|
||||
relationModel.setShapeId(toShapeId);
|
||||
relationModel.setShapeText(elements.getJSONObject(toShapeId).getString("text"));
|
||||
relationModel.setRelationFileId(roleRelationObj.getString("modelId"));
|
||||
relationModel.setRelationShapeId(roleRelationObj.getString("shapeId"));
|
||||
relationModel.setRelationShapeText(roleRelationObj.getString("shapeText"));
|
||||
relationList.add(relationModel);
|
||||
JSONArray dataAttributes = elements.getJSONObject(toShapeId).getJSONArray("dataAttributes");
|
||||
if (!dataAttributes.isEmpty() && dataAttributes.size() > 0) {
|
||||
JSONObject tempRelationObj = new JSONObject();
|
||||
tempRelationObj.put("value", "");
|
||||
tempRelationObj.put("key", attributeModel.getKey());
|
||||
tempRelationObj.put("isRequired", attributeModel.getIsRequired());
|
||||
tempRelationObj.put("ref", attributeModel.getRef());
|
||||
tempRelationObj.put("readonly", attributeModel.getReadonly());
|
||||
tempRelationObj.put("scope", attributeModel.getScope());
|
||||
tempRelationObj.put("name", attributeModel.getTitle());
|
||||
tempRelationObj.put("id", attributeModel.getKey());
|
||||
tempRelationObj.put("type", attributeModel.getType());
|
||||
tempRelationObj.put("groupPath", attributeModel.getGroupPath());
|
||||
tempRelationObj.put("desc", attributeModel.getDesc());
|
||||
for (Object attribute : dataAttributes) {
|
||||
JSONObject obj = (JSONObject) attribute;
|
||||
if (obj.containsKey("attributesJsonArray")) {
|
||||
JSONArray attributesJsonArray = obj.getJSONArray("attributesJsonArray");
|
||||
JSONArray tempJSONArr = attributesJsonArray.stream()
|
||||
.filter(item -> ((JSONObject) item).getString("key").equals(attributeModel.getKey()))
|
||||
.collect(Collectors.toCollection(JSONArray::new));
|
||||
if (tempJSONArr.size() > 0) {
|
||||
attributesJsonArray.stream().forEach(item -> {
|
||||
if (attributeModel.getKey().equals(((JSONObject) item).getString("key"))) {
|
||||
((JSONObject) item).getJSONArray("value").add(roleShapeId);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
tempRelationObj.put("value", new JSONArray());
|
||||
tempRelationObj.getJSONArray("value").add(roleShapeId);
|
||||
attributesJsonArray.add(tempRelationObj);
|
||||
}
|
||||
break;
|
||||
} else {
|
||||
tempRelationObj.put("value", new JSONArray());
|
||||
tempRelationObj.getJSONArray("value").add(roleShapeId);
|
||||
obj.put("attributesJsonArray", new JSONArray());
|
||||
obj.getJSONArray("attributesJsonArray").add(tempRelationObj);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
// 删除图形与连线
|
||||
removeKey.add(key);
|
||||
removeKey.add(roleShapeId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, String> map = new HashMap<>();
|
||||
for (Map.Entry<String, String> entry : palShapeIdRelationArisOccIdMap.entrySet()) {
|
||||
String shapeId = entry.getKey();
|
||||
String arisShapeId = entry.getValue();
|
||||
if (arisFunIdRelationPalRoleMap.containsKey(arisShapeId)) {
|
||||
String roleShapeId = arisFunIdRelationPalRoleMap.get(arisShapeId);
|
||||
DesignerShapeRelationModel m = new DesignerShapeRelationModel();
|
||||
m.setId(UUIDGener.getUUID());
|
||||
m.setFileId(repositoryModelId);
|
||||
m.setShapeId(shapeId);
|
||||
m.setShapeText(elements.getJSONObject(shapeId).getString("text"));
|
||||
m.setRelationFileId(roleMdoelId);
|
||||
m.setRelationShapeId(roleShapeId);
|
||||
m.setRelationShapeText(palRoleIdRelationNameMap.get(roleShapeId));
|
||||
m.setAttrId(Constant.METHOD_ROLE);
|
||||
relationList.add(m);
|
||||
}
|
||||
}
|
||||
|
||||
Set<String> roleIdSet = new HashSet<>();
|
||||
for (String key : elements.keySet()) {
|
||||
JSONObject tempShapeObj = elements.getJSONObject(key);
|
||||
if ("role".equals(tempShapeObj.getString("name"))) {
|
||||
roleIdSet.add(key);
|
||||
}
|
||||
}
|
||||
for (String key : elements.keySet()) {
|
||||
JSONObject tempShapeObj = elements.getJSONObject(key);
|
||||
if ("linker".equals(tempShapeObj.getString("name"))) {
|
||||
String text = "";
|
||||
if (roleIdSet.contains(tempShapeObj.getJSONObject("from").getString("id"))) {
|
||||
text = elements.getJSONObject(tempShapeObj.getJSONObject("from").getString("id")).getString("text");
|
||||
// 删除图形与连线
|
||||
removeKey.add(key);
|
||||
removeKey.add(tempShapeObj.getJSONObject("from").getString("id"));
|
||||
} else if (roleIdSet.contains(tempShapeObj.getJSONObject("to").getString("id"))) {
|
||||
text = elements.getJSONObject(tempShapeObj.getJSONObject("to").getString("id")).getString("text");
|
||||
// 删除图形与连线
|
||||
removeKey.add(key);
|
||||
removeKey.add(tempShapeObj.getJSONObject("to").getString("id"));
|
||||
}
|
||||
printMsg("流程" + arisModel.getName() + "删除角色形状" + text + "和其连线");
|
||||
}
|
||||
}
|
||||
|
||||
// 保存关联关系
|
||||
if (relationList.size() > 0) {
|
||||
DesignerShapeRelationDao relationDao = new DesignerShapeRelationDao();
|
||||
@ -1183,268 +1286,6 @@ public class DataMigrationWeb extends ActionWeb {
|
||||
removeKey.stream().forEach(key -> elements.remove(key));
|
||||
}
|
||||
|
||||
/**
|
||||
* 处理角色图
|
||||
*
|
||||
* @param wsId
|
||||
* @param idRelationMap
|
||||
* @param arisModel
|
||||
* @param modelObjOccMap
|
||||
* @param objDefMap
|
||||
*/
|
||||
private void handleRoleShape(String wsId, List<ModelModel> currentModelNoShape, String parentId, Map<String, JSONObject> positionShapeRelationMap, Map<String, JSONObject> idRelationMap, ModelModel arisModel, Map<String, List<ObjOccModel>> modelObjOccMap, Map<String, ObjDefModel> objDefMap, Map<String, List<CxnOccModel>> cxnOccMap) {
|
||||
// 存储没有图形的流程
|
||||
List<ObjOccModel> objOccModels = modelObjOccMap.get(arisModel.getId());
|
||||
if (objOccModels == null || objOccModels.size() == 0) {
|
||||
currentModelNoShape.add(arisModel);
|
||||
return;
|
||||
}
|
||||
// 生成一个空的与流程同名角色模型文件 【暂时放到ORG大类下】
|
||||
String id = UUIDGener.getUUID();
|
||||
String plRid = UUIDGener.getUUID();
|
||||
PALRepository coeProcessLevel = CoeProcessLevelDaoFacotory.createCoeProcessLevel();
|
||||
int orderIndex = coeProcessLevel.getChildrenMaxOrderIndexByPidAndWsId("org", wsId) + 1;
|
||||
Timestamp nowTime = new Timestamp(System.currentTimeMillis());
|
||||
|
||||
// 替换创建角色图--by shang
|
||||
// PALRepositoryModelImpl model = CoeProcessLevelUtil.createPALRepositoryModel(id, plRid, wsId, arisModel.getName(), "", orderIndex, parentId, "org", true, 1,
|
||||
// id, false, "org.normal", "0", 1, null, null, _uc.getUID(), _uc.getUID(), nowTime, null, null, null, null,
|
||||
// null, null, null, null, null,-1);
|
||||
PALRepositoryModelImpl model = CoeProcessLevelUtil.createPALRepositoryModel(id, plRid, wsId, arisModel.getName(), "", orderIndex, parentId, "org", true, 1,
|
||||
id, false, "org.role", "0", 1, null, null, _uc.getUID(), _uc.getUID(), nowTime, null, null, null, null,
|
||||
null, null, null, null, null, -1);
|
||||
coeProcessLevel.insert(model);
|
||||
printMsg("与流程同名的角色空模型创建完毕【文件ID】" + model.getId());
|
||||
BaseModel baseModel = CoeDesignerAPIManager.getInstance().getDefinition(model.getId(), 0);
|
||||
if (baseModel == null) {
|
||||
baseModel = CoeDesignerUtil.createModel(model.getId(), 0);
|
||||
baseModel.setCreateHistory(false);
|
||||
}
|
||||
baseModel.setUpdateTime(new SimpleDateFormat(CoeDesignerConstant.DATE_TIME_STYLE_YYYY_MM_DD_HH_MM_SS).format(new Date()));
|
||||
String define = baseModel.getDefinition();
|
||||
JSONObject definition = JSONObject.parseObject(define);
|
||||
JSONObject elements = definition.getJSONObject("elements");
|
||||
if (elements != null && !elements.isEmpty()) {
|
||||
// 导入模型已存在数据,不允许导入 todo
|
||||
printMsg("导入模型已存在数据,不允许导入");
|
||||
return;
|
||||
}
|
||||
// 将ARIS中当前模型下的角色图找出来转化成对应PAL的角色图 【ARIS那边有同名不同ID的图 转化成PAL角色模型图时根据名称去重就可以】
|
||||
// 获取ARIS角色图形定义与PAL角色图形定义映射关系
|
||||
Map<String, ObjDefMappingModel> objDefMappingMap = ModelMappingAPIManager.getInstance().getObjDefMappingMap();
|
||||
ObjDefMappingModel objDefMappingModel = objDefMappingMap.get("OT_PERS_TYPE-ST_EMPL_TYPE");
|
||||
if (objDefMappingModel == null) {
|
||||
printMsg("未找到ARIS角色图与PAL角色图定义的映射关系信息");
|
||||
}
|
||||
int zindex = 1;
|
||||
JSONArray shapes = new JSONArray();
|
||||
List<PALMethodAttributeModel> attributeModels = CoeDesignerShapeAPIManager.getInstance()
|
||||
.getValidAttributeModels(wsId, objDefMappingModel.getShapeMethod(), "org", objDefMappingModel.getShapeMethod());
|
||||
attributeModels = attributeModels.stream().filter(item -> Constant.METHOD_POST.equals(item.getKey())).collect(Collectors.toList());
|
||||
PALMethodAttributeModel attributeModel = attributeModels.get(0);
|
||||
|
||||
// 流程关联属性结果集
|
||||
List<DesignerShapeRelationModel> relationList = new ArrayList<>();
|
||||
|
||||
for (ObjOccModel objOccModel : objOccModels) {
|
||||
ObjDefModel objDefModel = objDefMap.get(objOccModel.getDefId());
|
||||
if (objDefModel.getSymbolNum().equals(objDefMappingModel.getSymbolNum()) && objDefModel.getTypeNum().equals(objDefMappingModel.getTypeNum())) {
|
||||
|
||||
String shapeMethodId = objDefMappingModel.getShapeMethod();
|
||||
String shapeType = objDefMappingModel.getShapeType();
|
||||
JSONObject shape = ShapeUtil.getProcessShapeDefinitionByName(shapeMethodId, shapeType);
|
||||
String shapeId = UUIDGener.getObjectId();
|
||||
|
||||
shape.put("id", shapeId);
|
||||
String name = objDefMap.get(objOccModel.getDefId()).getName();// 形状名称
|
||||
shape.put("text", name);
|
||||
|
||||
JSONObject props = shape.getJSONObject("props");// 位置大小
|
||||
props.put("zindex", zindex++);
|
||||
props.put("x", objOccModel.getX());
|
||||
props.put("y", objOccModel.getY());
|
||||
props.put("w", objOccModel.getW());
|
||||
props.put("h", objOccModel.getH());
|
||||
|
||||
JSONArray values = new JSONArray();
|
||||
JSONObject postObj = new JSONObject();
|
||||
postObj.put("value", "");
|
||||
postObj.put("key", attributeModel.getKey());
|
||||
postObj.put("isRequired", attributeModel.getIsRequired());
|
||||
postObj.put("ref", attributeModel.getRef());
|
||||
postObj.put("readonly", attributeModel.getReadonly());
|
||||
postObj.put("scope", attributeModel.getScope());
|
||||
postObj.put("name", attributeModel.getTitle());
|
||||
postObj.put("id", attributeModel.getKey());
|
||||
postObj.put("type", attributeModel.getType());
|
||||
postObj.put("groupPath", attributeModel.getGroupPath());
|
||||
postObj.put("desc", attributeModel.getDesc());
|
||||
// 将岗位信息作为活动属性放到对应位置 todo
|
||||
if (cxnOccMap.containsKey(objOccModel.getId())) {
|
||||
List<CxnOccModel> cxnOccModels = cxnOccMap.get(objOccModel.getId());
|
||||
for (CxnOccModel cxnOccModel : cxnOccModels) {
|
||||
if (positionShapeRelationMap.containsKey(cxnOccModel.getToId())) {
|
||||
JSONObject relationObj = positionShapeRelationMap.get(cxnOccModel.getToId());
|
||||
DesignerShapeRelationModel relationModel = new DesignerShapeRelationModel();
|
||||
relationModel.setFileId(model.getId());
|
||||
relationModel.setAttrId(Constant.METHOD_POST);
|
||||
relationModel.setId(UUIDGener.getUUID());
|
||||
relationModel.setShapeId(shapeId);
|
||||
relationModel.setShapeText(name);
|
||||
relationModel.setRelationFileId(relationObj.getString("modelId"));
|
||||
relationModel.setRelationShapeId(relationObj.getString("shapeId"));
|
||||
relationModel.setRelationShapeText(relationObj.getString("shapeText"));
|
||||
relationList.add(relationModel);
|
||||
values.add(relationObj.getString("shapeId"));
|
||||
printMsg("岗位【" + relationObj.getString("shapeText") + "】关联到角色【" + name + "】");
|
||||
}
|
||||
}
|
||||
if (values.size() > 0) {
|
||||
postObj.put("value", values);
|
||||
JSONArray dataAttributes = shape.getJSONArray("dataAttributes");
|
||||
if (!dataAttributes.isEmpty() && dataAttributes.size() > 0) {
|
||||
for (Object attribute : dataAttributes) {
|
||||
JSONObject obj = (JSONObject) attribute;
|
||||
if (obj.containsKey("attributesJsonArray")) {
|
||||
obj.getJSONArray("attributesJsonArray").add(postObj);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
shapes.add(shape);
|
||||
JSONObject roleObj = new JSONObject();
|
||||
roleObj.put("modelId", model.getId());
|
||||
roleObj.put("shapeId", shapeId);
|
||||
roleObj.put("shapeText", name);
|
||||
idRelationMap.put(objOccModel.getId(), roleObj);// 记录形状aris形状id与pal形状id
|
||||
}
|
||||
}
|
||||
// 保存关联关系
|
||||
if (relationList.size() > 0) {
|
||||
DesignerShapeRelationDao relationDao = new DesignerShapeRelationDao();
|
||||
relationDao.barchInsert(relationList);
|
||||
}
|
||||
//
|
||||
printMsg("去重前角色个数 " + shapes.size());
|
||||
// shapes = shapes.stream().distinct().collect(Collectors.toCollection(JSONArray::new));
|
||||
// JSONArray arr= shapes.stream().filter(distinctByKey(item -> ((JSONObject)item).getString("value"))).collect(Collectors.toList()));
|
||||
// 去重--by shang
|
||||
shapes = JSONArray.parseArray(shapes.stream().filter(distinctByKey(item -> ((JSONObject) item).getString("text"))).collect(Collectors.toList()).toString());
|
||||
|
||||
printMsg("去重后角色个数 " + shapes.size());
|
||||
JSONArray newShapes = this.getMethodElementsJSONArray(shapes, 6);
|
||||
JSONObject newElements = new JSONObject();
|
||||
for (int i = 0; i < newShapes.size(); i++) {
|
||||
JSONObject shapeObj = newShapes.getJSONObject(i);
|
||||
newElements.put(shapeObj.getString("id"), shapeObj);
|
||||
printMsg("生成角色图 【" + shapeObj.getString("text") + "】");
|
||||
}
|
||||
|
||||
definition.put("elements", newElements);
|
||||
// 设置画布大小
|
||||
setDiagramHeightWidth(definition, newElements);
|
||||
baseModel.setDefinition(definition.toString());
|
||||
// 保存文件
|
||||
CoeDesignerAPIManager.getInstance().storeDefinition(baseModel);// dao操作
|
||||
}
|
||||
|
||||
/**
|
||||
* 处理岗位信息
|
||||
*
|
||||
* @param wsId
|
||||
* @param relationJsonObjMap
|
||||
* @param arisModel
|
||||
* @param modelObjOccMap
|
||||
* @param objDefMap
|
||||
*/
|
||||
private void handlePositionShape(String parentId, String wsId, List<ModelModel> currentModelNoShape, Map<String, JSONObject> relationJsonObjMap, ModelModel arisModel, Map<String, List<ObjOccModel>> modelObjOccMap, Map<String, ObjDefModel> objDefMap) {
|
||||
// 存储没有图形的流程
|
||||
List<ObjOccModel> objOccModels = modelObjOccMap.get(arisModel.getId());
|
||||
if (objOccModels == null || objOccModels.size() == 0) {
|
||||
currentModelNoShape.add(arisModel);
|
||||
return;
|
||||
}
|
||||
// 生成存储岗位信息的模型文件【可以隐藏 ParentId设置成随机的】在模型文件信息里存储ARIS旧岗位信息比如ID 方便后续根据这个ID能找到对应的
|
||||
// 生成一个空的与流程同名岗位模型文件
|
||||
String id = UUIDGener.getUUID();
|
||||
String plRid = UUIDGener.getUUID();
|
||||
PALRepository coeProcessLevel = CoeProcessLevelDaoFacotory.createCoeProcessLevel();
|
||||
int orderIndex = coeProcessLevel.getChildrenMaxOrderIndexByPidAndWsId("org", wsId) + 1;
|
||||
Timestamp nowTime = new Timestamp(System.currentTimeMillis());
|
||||
|
||||
PALRepositoryModelImpl model = CoeProcessLevelUtil.createPALRepositoryModel(id, plRid, wsId, arisModel.getName(), "", orderIndex, parentId, "org", true, 1,
|
||||
id, false, "org.normal", "0", 1, null, null, _uc.getUID(), _uc.getUID(), nowTime, null, null, null, null,
|
||||
null, null, null, null, null, -1);
|
||||
coeProcessLevel.insert(model);
|
||||
printMsg("与流程同名的岗位空模型【隐藏的】创建完毕【文件ID】" + model.getId());
|
||||
BaseModel baseModel = CoeDesignerAPIManager.getInstance().getDefinition(model.getId(), 0);
|
||||
if (baseModel == null) {
|
||||
baseModel = CoeDesignerUtil.createModel(model.getId(), 0);
|
||||
baseModel.setCreateHistory(false);
|
||||
}
|
||||
baseModel.setUpdateTime(new SimpleDateFormat(CoeDesignerConstant.DATE_TIME_STYLE_YYYY_MM_DD_HH_MM_SS).format(new Date()));
|
||||
String define = baseModel.getDefinition();
|
||||
JSONObject definition = JSONObject.parseObject(define);
|
||||
JSONObject elements = definition.getJSONObject("elements");
|
||||
if (elements != null && !elements.isEmpty()) {
|
||||
// 导入模型已存在数据,不允许导入 todo
|
||||
printMsg("导入模型已存在数据,不允许导入");
|
||||
return;
|
||||
}
|
||||
Map<String, ObjDefMappingModel> objDefMappingMap = ModelMappingAPIManager.getInstance().getObjDefMappingMap();
|
||||
ObjDefMappingModel objDefMappingModel = objDefMappingMap.get("OT_POS-ST_POS");
|
||||
if (objDefMappingModel == null) {
|
||||
printMsg("未找到ARIS岗位图与PAL岗位图定义的映射关系信息");
|
||||
}
|
||||
int zindex = 1;
|
||||
JSONArray shapes = new JSONArray();
|
||||
for (ObjOccModel objOccModel : objOccModels) {
|
||||
ObjDefModel objDefModel = objDefMap.get(objOccModel.getDefId());
|
||||
if (objDefModel.getSymbolNum().equals(objDefMappingModel.getSymbolNum()) && objDefModel.getTypeNum().equals(objDefMappingModel.getTypeNum())) {
|
||||
|
||||
String shapeMethodId = objDefMappingModel.getShapeMethod();
|
||||
String shapeType = objDefMappingModel.getShapeType();
|
||||
JSONObject shape = ShapeUtil.getProcessShapeDefinitionByName(shapeMethodId, shapeType);
|
||||
String shapeId = UUIDGener.getObjectId();
|
||||
shape.put("id", shapeId);
|
||||
// 记录下ARIS相关信息 方便后续根据映射关系能找到对应的PAL信息
|
||||
shape.put("arisModelId", arisModel.getId());
|
||||
shape.put("arisShapeId", objOccModel.getId());
|
||||
shape.put("arisShapeDefId", objOccModel.getDefId());
|
||||
String name = objDefMap.get(objOccModel.getDefId()).getName();// 形状名称
|
||||
shape.put("text", name);
|
||||
|
||||
JSONObject props = shape.getJSONObject("props");// 位置大小
|
||||
props.put("zindex", zindex++);
|
||||
props.put("x", objOccModel.getX());
|
||||
props.put("y", objOccModel.getY());
|
||||
props.put("w", objOccModel.getW());
|
||||
props.put("h", objOccModel.getH());
|
||||
shapes.add(shape);
|
||||
JSONObject positionObj = new JSONObject();
|
||||
positionObj.put("modelId", model.getId());
|
||||
positionObj.put("shapeId", shapeId);
|
||||
positionObj.put("shapeText", name);
|
||||
relationJsonObjMap.put(objOccModel.getId(), positionObj);// 记录形状aris形状id与pal形状id
|
||||
}
|
||||
}
|
||||
JSONArray newShapes = this.getMethodElementsJSONArray(shapes, 6);
|
||||
JSONObject newElements = new JSONObject();
|
||||
for (int i = 0; i < newShapes.size(); i++) {
|
||||
JSONObject shapeObj = newShapes.getJSONObject(i);
|
||||
newElements.put(shapeObj.getString("id"), shapeObj);
|
||||
printMsg("生成岗位图 【" + shapeObj.getString("text") + "】");
|
||||
}
|
||||
definition.put("elements", newElements);
|
||||
// 设置画布大小
|
||||
setDiagramHeightWidth(definition, newElements);
|
||||
baseModel.setDefinition(definition.toString());
|
||||
// 保存文件
|
||||
CoeDesignerAPIManager.getInstance().storeDefinition(baseModel);// dao操作
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建具有合理位置的节点数据
|
||||
*
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
|
||||
<attributes type="customer">
|
||||
<attribute key="post" title="岗位" type="string" value="" desc="1" isRequired="false" ref="" readonly="false" groupPath="baseAttribute" scope="%,*" isValid="true"/>
|
||||
<attribute key="post" title="岗位" type="string" value="" desc="1" isRequired="false" ref="" readonly="false" groupPath="baseAttribute" scope="%,*" isValid="true"/>
|
||||
<attribute key="post_text" title="岗位文本" type="string" value="" desc="岗位文本信息" isRequired="false" ref="" readonly="false" groupPath="baseAttribute" scope="*" isValid="true"/>
|
||||
</attributes>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user