|
@@ -18,18 +18,12 @@ import java.util.Map;
|
|
|
public class CaseExportLogicImpl implements CaseExportLogic, Serializable {
|
|
|
|
|
|
@Autowired
|
|
|
- private MongoDBConfiguration mongoDBConfiguration;
|
|
|
-
|
|
|
- @Autowired
|
|
|
private CaseExportService caseExportService;
|
|
|
|
|
|
@Override
|
|
|
public Map<String, Object> exportCases(List<Long> caseIds, String filePath, String zipFileName, String fileName) {
|
|
|
String ossFilePath = "download/";
|
|
|
Map<String, Object> fileMap = new HashMap<>();
|
|
|
- String mongoUrl = "http://" + mongoDBConfiguration.getHost() + ":" + mongoDBConfiguration.getPort() + "/";
|
|
|
- String getCaseUrl = mongoUrl + mongoDBConfiguration.getDb() + "/" + mongoDBConfiguration.getCaseGraghCollection();
|
|
|
- String getTargetUrl = mongoUrl + mongoDBConfiguration.getDb() + "/" + mongoDBConfiguration.getTargetGraphCollection();
|
|
|
String tempFilePath = filePath + "temp/";
|
|
|
String zipFilePath = filePath + zipFileName;
|
|
|
Map<String, Object> res = new HashMap<>();
|
|
@@ -41,7 +35,6 @@ public class CaseExportLogicImpl implements CaseExportLogic, Serializable {
|
|
|
}
|
|
|
try {
|
|
|
//导出msyql
|
|
|
- //TODO 去掉tempFilePath参数
|
|
|
HashMap<String, Object> map = caseExportService.exportMysql(caseIds);
|
|
|
targetIds = (List<Long>) map.get("targetIds");
|
|
|
fileMap.put("mysqlFile", map.get("mysqlFile"));
|
|
@@ -53,7 +46,6 @@ public class CaseExportLogicImpl implements CaseExportLogic, Serializable {
|
|
|
}
|
|
|
try {
|
|
|
//导出mongo
|
|
|
- //TODO 去掉tempFilePath参数
|
|
|
HashMap<String, Object> map = caseExportService.exportMongo(caseIds, targetIds);
|
|
|
fileMap.put("mongoCaseFile", map.get("mongoCaseFile"));
|
|
|
fileMap.put("mongoTargetFile", map.get("mongoTargetFile"));
|