diff --git a/com.actionsoft.apps.coe.pal/lib/com.actionsoft.apps.coe.pal.jar b/com.actionsoft.apps.coe.pal/lib/com.actionsoft.apps.coe.pal.jar index 1e9c53d2..57cdf619 100644 Binary files a/com.actionsoft.apps.coe.pal/lib/com.actionsoft.apps.coe.pal.jar and b/com.actionsoft.apps.coe.pal/lib/com.actionsoft.apps.coe.pal.jar differ diff --git a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/PALRepositoryQueryAPIManager.java b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/PALRepositoryQueryAPIManager.java index faec36c9..2a11e0c6 100755 --- a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/PALRepositoryQueryAPIManager.java +++ b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/PALRepositoryQueryAPIManager.java @@ -5217,7 +5217,28 @@ public class PALRepositoryQueryAPIManager { break; } } - } else { + } else if ("shapeAndFile".equals(relationTyp)) {// 关联的模型形状和文件都有 伊利 + if (UtilString.isEmpty(model.getRelationShapeId())) {// 关联文件,发现记录的不是versionID,而是id 伊利 + PALRepositoryModel relationModel = PALRepositoryCache.getCache().get(model.getRelationFileId()); + if (relationModel != null) { + inputValueList.add(relationModel.getName()); + JSONObject tmp = new JSONObject(); + tmp.put("fileId", relationModel.getId()); + tmp.put("name", relationModel.getName()); + tmp.put("isFile", true); + attrObj.getJSONArray("value").add(tmp); + } + } else { + // 关联形状 + inputValueList.add(model.getRelationShapeText()); + JSONObject tmp = new JSONObject(); + tmp.put("fileId", model.getRelationFileId()); + tmp.put("shapeId", model.getRelationShapeId()); + tmp.put("name", model.getRelationShapeText()); + tmp.put("isFile", false); + attrObj.getJSONArray("value").add(tmp); + } + } else {// 关联的模型形状 inputValueList.add(model.getRelationShapeText()); JSONObject tmp = new JSONObject(); tmp.put("fileId", model.getRelationFileId()); @@ -5410,6 +5431,27 @@ public class PALRepositoryQueryAPIManager { } } } + } else if ("shapeAndFile".equals(relationType)) {// 关联的模型形状和文件都有 伊利 + if (UtilString.isEmpty(relationModel.getRelationShapeId())) {// 关联文件,发现记录的不是versionID,而是id 伊利 + PALRepositoryModel plModel = PALRepositoryCache.getCache().get(relationModel.getRelationFileId()); + if (plModel != null) { + inputValues.add(plModel.getName()); + JSONObject tmp = new JSONObject(); + tmp.put("fileId", plModel.getId()); + tmp.put("name", plModel.getName()); + tmp.put("isFile", true); + attrObj.getJSONArray("value").add(tmp); + } + } else { + // 关联形状 + inputValues.add(relationModel.getRelationShapeText()); + JSONObject tmp = new JSONObject(); + tmp.put("fileId", relationModel.getRelationFileId()); + tmp.put("shapeId", relationModel.getRelationShapeId()); + tmp.put("name", relationModel.getRelationShapeText()); + tmp.put("isFile", false); + attrObj.getJSONArray("value").add(tmp); + } } else {// 形状属性 inputValues.add(relationModel.getRelationShapeText()); JSONObject tmp = new JSONObject(); diff --git a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/CoeDesignerShapeAPIManager.java b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/CoeDesignerShapeAPIManager.java index bfe2c4ce..f4727e82 100755 --- a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/CoeDesignerShapeAPIManager.java +++ b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/CoeDesignerShapeAPIManager.java @@ -1066,6 +1066,18 @@ public class CoeDesignerShapeAPIManager { for (DesignerShapeRelationModel model : relationModels) { textList.add(model.getRelationShapeText()); } + } else if("shapeAndFile".equals(relationType)) {// 关联形状和文件 + for (DesignerShapeRelationModel model : relationModels) { + if (UtilString.isEmpty(model.getRelationShapeId())) {// 关联文件,发现记录的不是versionID,而是id 伊利 + PALRepositoryModel relationModel = PALRepositoryCache.getCache().get(model.getRelationFileId()); + if (relationModel != null) { + textList.add(relationModel.getName()); + } + } else { + // 关联形状 + textList.add(model.getRelationShapeText()); + } + } } else {// 关联文件 for (DesignerShapeRelationModel model : relationModels) { String versionId = model.getRelationFileId(); diff --git a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/util/ShapeUtil.java b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/util/ShapeUtil.java index 87c7a47b..6ca316ef 100755 --- a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/util/ShapeUtil.java +++ b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/designer/util/ShapeUtil.java @@ -201,6 +201,16 @@ public class ShapeUtil { } } } + } else if ("shapeAndFile".equals(relationType)) {// 关联的模型形状和文件都有 伊利 + if (UtilString.isEmpty(relationModel.getRelationShapeId())) {// 关联文件,发现记录的不是versionID,而是id 伊利 + PALRepositoryModel plModel = PALRepositoryCache.getCache().get(relationModel.getRelationFileId()); + if (plModel != null) { + inputValues.add(plModel.getName()); + } + } else { + // 关联形状 + inputValues.add(relationModel.getRelationShapeText()); + } } else {// 形状属性 inputValues.add(relationModel.getRelationShapeText()); } diff --git a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/util/CoeProcessLevelUtil.java b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/util/CoeProcessLevelUtil.java index 946d2788..404d4896 100755 --- a/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/util/CoeProcessLevelUtil.java +++ b/com.actionsoft.apps.coe.pal/src/com/actionsoft/apps/coe/pal/pal/repository/util/CoeProcessLevelUtil.java @@ -2200,7 +2200,17 @@ public class CoeProcessLevelUtil { break; } } - } else { + } else if ("shapeAndFile".equals(relationTyp)) {// 关联的有形状属性和文件属性 伊利 + if (UtilString.isEmpty(model.getRelationShapeId())) {// 关联文件,发现记录的不是versionID,而是id 伊利 + PALRepositoryModel relationModel = PALRepositoryCache.getCache().get(model.getRelationFileId()); + if (relationModel != null) { + inputValueList.add(relationModel.getName()); + } + } else { + // 关联形状 + inputValueList.add(model.getRelationShapeText()); + } + } else {// 关联的形状属性 inputValueList.add(model.getRelationShapeText()); } }