|
@@ -205,11 +205,11 @@ public class ExtractKnowledgeSubTaskServiceImpl implements IExtractKnowledgeSubT
|
|
if (ExtractKnowledgeSubTask.REVIEWED.equals(status)) {
|
|
if (ExtractKnowledgeSubTask.REVIEWED.equals(status)) {
|
|
|
|
|
|
// save resultJson
|
|
// save resultJson
|
|
- String resultPath = sysDictDataService.getValueByTypeAndValue("kg_algorithm", "resultPath");
|
|
|
|
|
|
+// String resultPath = sysDictDataService.getValueByTypeAndValue("kg_algorithm", "resultPath");
|
|
String result = extractResult.getResultData();
|
|
String result = extractResult.getResultData();
|
|
|
|
|
|
try {
|
|
try {
|
|
- FileUtils.writeJsonToFile(result,resultPath+extractResult.getResult());
|
|
|
|
|
|
+ FileUtils.writeJsonToFile(result,extractResult.getResult());
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
logger.error("抽取结果保存失败");
|
|
logger.error("抽取结果保存失败");
|
|
}
|
|
}
|
|
@@ -273,12 +273,12 @@ public class ExtractKnowledgeSubTaskServiceImpl implements IExtractKnowledgeSubT
|
|
|
|
|
|
private void processSuccess(KgDocDTO kgDocDTO) {
|
|
private void processSuccess(KgDocDTO kgDocDTO) {
|
|
Long subTaskId = kgDocDTO.getDocInfo().getSubTaskId();
|
|
Long subTaskId = kgDocDTO.getDocInfo().getSubTaskId();
|
|
- String dictValue = sysDictDataService.getValueByTypeAndValue("kg_algorithm","resultPath");
|
|
|
|
|
|
+// String dictValue = sysDictDataService.getValueByTypeAndValue("kg_algorithm","resultPath");
|
|
ExtractResult extractResultDb = extractResultService.getResultBySubTaskId(subTaskId);
|
|
ExtractResult extractResultDb = extractResultService.getResultBySubTaskId(subTaskId);
|
|
String resultPath = kgDocDTO.getResultPath();
|
|
String resultPath = kgDocDTO.getResultPath();
|
|
- if(StringUtils.isNotBlank(resultPath) && StringUtils.isNotBlank(dictValue)){
|
|
|
|
- resultPath = resultPath.replace(dictValue,"");
|
|
|
|
- }
|
|
|
|
|
|
+// if(StringUtils.isNotBlank(resultPath) && StringUtils.isNotBlank(dictValue)){
|
|
|
|
+// resultPath = resultPath.replace(dictValue,"");
|
|
|
|
+// }
|
|
if(extractResultDb == null) {
|
|
if(extractResultDb == null) {
|
|
ExtractResult extractResult = new ExtractResult();
|
|
ExtractResult extractResult = new ExtractResult();
|
|
extractResult.setSubTaskId(subTaskId);
|
|
extractResult.setSubTaskId(subTaskId);
|