diff --git a/com.actionsoft.apps.coe.pal.output.pr/lib/com.actionsoft.apps.coe.pal.output.pr.jar b/com.actionsoft.apps.coe.pal.output.pr/lib/com.actionsoft.apps.coe.pal.output.pr.jar index ae1500fb..81cc9ded 100644 Binary files a/com.actionsoft.apps.coe.pal.output.pr/lib/com.actionsoft.apps.coe.pal.output.pr.jar and b/com.actionsoft.apps.coe.pal.output.pr/lib/com.actionsoft.apps.coe.pal.output.pr.jar differ diff --git a/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/report1/Report1Gener.java b/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/report1/Report1Gener.java index bb87cd16..66169ee3 100644 --- a/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/report1/Report1Gener.java +++ b/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/report1/Report1Gener.java @@ -558,7 +558,7 @@ public class Report1Gener { //支持文件 JSONArray supportfiles = new JSONArray(); - try { + /*try { int count = 0; String sql = "select PROPERTYVALUE from APP_ACT_COE_PAL_PROP where PLID = '"+repositoryModel.getId()+"' and PROPERTYID = 'support_files'"; String relatFileJson = DBSql.getString(sql); @@ -579,9 +579,37 @@ public class Report1Gener { } } catch (Exception e) { // TODO: handle exception + }*/ + + + + + List relationList = DesignerShapeRelationCache.getListByAttrId(repositoryModel.getId(), "", "support_files"); + + relationList.sort(Comparator.comparing(DesignerShapeRelationModel::getShapeText)); + + int index = 0; + if (relationList.size() > 0) { + for (DesignerShapeRelationModel relation : relationList) { + String relationFileId = relation.getRelationFileId();// 支持或相关文件的ID + String name = null; + List models = PALRepositoryCache.getByVersionId(relationFileId); + if (models != null && models.size() > 0) { + index++; + for (PALRepositoryModel oneModel : models) { + if (oneModel.isUse() == true) { + name = oneModel.getName(); + } + } + } + + JSONObject tmp = new JSONObject(); + tmp.put("name", name); + tmp.put("desc", index); + supportfiles.add(tmp); + } } - - + /* * List relationList = * DesignerShapeRelationCache.getListByAttrId(repositoryModel.getId(), "", @@ -603,12 +631,13 @@ public class Report1Gener { try { //相关文件 - int count = 0; + /*int count = 0; String sql = "select PROPERTYVALUE from APP_ACT_COE_PAL_PROP where PLID = '"+repositoryModel.getId()+"' and PROPERTYID = 'R_relevant_flies'"; String relatFileJson = DBSql.getString(sql); if(UtilString.isNotEmpty(relatFileJson)) { JSONObject parseObject = JSONObject.parseObject(relatFileJson); String fileNames = parseObject.getString("relationShapeText"); + String relationFileId=parseObject.getString("relationFileId"); if(UtilString.isNotEmpty(fileNames)) { String[] names = fileNames.split(","); for (String name : names) { @@ -619,9 +648,37 @@ public class Report1Gener { relevant_flies.add(tmp); } } - + }*/ + + + List relationList2 = DesignerShapeRelationCache.getListByAttrId(repositoryModel.getId(), "", "R_relevant_flies"); + + relationList2.sort(Comparator.comparing(DesignerShapeRelationModel::getShapeText)); + + + int count = 0; + if (relationList2.size() > 0) { + for (DesignerShapeRelationModel relation : relationList2) { + String relationFileId = relation.getRelationFileId();// 支持或相关文件的ID + String name = null; + List models = PALRepositoryCache.getByVersionId(relationFileId); + if (models != null && models.size() > 0) { + count++; + for (PALRepositoryModel oneModel : models) { + if (oneModel.isUse() == true) { + name = oneModel.getName(); + } + } + } + JSONObject tmp = new JSONObject(); + tmp.put("name", name); + tmp.put("desc", count); + relevant_flies.add(tmp); + + } + } - + //外部相关文件 String sqlOut = "select PROPERTYVALUE from APP_ACT_COE_PAL_PROP where PLID = '"+repositoryModel.getId()+"' and PROPERTYID = 'Out_relevant_files'"; String outRelatFileJson = DBSql.getString(sqlOut); diff --git a/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/util/PrReportComment.java b/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/util/PrReportComment.java index b3d74201..daf73d3b 100644 --- a/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/util/PrReportComment.java +++ b/com.actionsoft.apps.coe.pal.output.pr/src/com/actionsoft/apps/coe/pal/output/pr/util/PrReportComment.java @@ -28,7 +28,7 @@ import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONObject; public class PrReportComment { - public static String TARGET_METHOD_SCOPE = "process.bpmn2,process.epc,process.flowchart,process.scheme"; + public static String TARGET_METHOD_SCOPE = "process.bpmn2,process.epc,process.flowchart"; public static String PROCESS_STEP = "userTask,serviceTask,manualTask,receiveTask,sendTask,scriptTask,businessRuleTask,callActivityCallingProcess,method,process,predefinedProcess,decision"; /**