|
@@ -7,7 +7,6 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
|
|
import java.util.List;
|
|
|
import java.util.Map;
|
|
|
-import java.util.stream.Collectors;
|
|
|
|
|
|
/**
|
|
|
* @Description:
|
|
@@ -27,16 +26,22 @@ public class BeiLunConsultationHtmlAnalysis implements BeiLunHtmlAnalysis {
|
|
|
String recTitle = args[1];
|
|
|
Map<String, String> structureMap = Maps.newLinkedHashMap();
|
|
|
List<String> htmlText = null;
|
|
|
+ String htmlContent = null;
|
|
|
switch (recTitle) {
|
|
|
case "377":
|
|
|
- htmlText = commonAnalysisUtil.html2List(html, true);
|
|
|
- commonAnalysisUtil.removeRepeat(htmlText);
|
|
|
- commonAnalysisUtil.html2StructureMap(titles, htmlText, structureMap);
|
|
|
+ htmlContent = commonAnalysisUtil.html2String(html);
|
|
|
+ if (StringUtil.isNotBlank(htmlContent)) {
|
|
|
+ htmlContent = htmlContent.replaceAll("[ ]", " ");
|
|
|
+ commonAnalysisUtil.html2StructureMap(titles, htmlContent, structureMap);
|
|
|
+ }
|
|
|
structureMap.put("rec_title=", recTitle);
|
|
|
break;
|
|
|
case "7883":
|
|
|
- htmlText = commonAnalysisUtil.html2List(html, false);
|
|
|
- commonAnalysisUtil.html2StructureMap(titles, htmlText, structureMap);
|
|
|
+ htmlContent = commonAnalysisUtil.html2String(html);
|
|
|
+ if (StringUtil.isNotBlank(htmlContent)) {
|
|
|
+ htmlContent = htmlContent.replaceAll("[ ]", " ");
|
|
|
+ commonAnalysisUtil.html2StructureMap(titles, htmlContent, structureMap);
|
|
|
+ }
|
|
|
if (StringUtil.isNotBlank(structureMap.get("会诊时间"))) {
|
|
|
String[] strArr = structureMap.get("会诊时间").split(" ");
|
|
|
structureMap.put("会诊意见", strArr[strArr.length - 1]);
|
|
@@ -46,18 +51,22 @@ public class BeiLunConsultationHtmlAnalysis implements BeiLunHtmlAnalysis {
|
|
|
break;
|
|
|
case "8084":
|
|
|
titles = Lists.newArrayList("姓名", "性别", "出生日期", "联系电话",
|
|
|
- "申请科室","入院/首诊时间", "住院号", "病情概述(含主诉、病史、诊断、诊治过程等)", "拟申请MDT时间、地点",
|
|
|
+ "申请科室", "入院/首诊时间", "住院号", "病情概述(含主诉、病史、诊断、诊治过程等)", "拟申请MDT时间、地点",
|
|
|
"拟请MDT参加科室", "MDT目的", "申请人签名", "申请递交时间", "科主任签字", "专家诊治建议", "专家科室", "签名",
|
|
|
- "填写时间","主持科室小结(MDT的最终诊治决议)","科主任(主持人)签名","记录人(主管医师)签字","日期");
|
|
|
- htmlText = Lists.newArrayList();
|
|
|
- commonAnalysisUtil.html2ListByTable(html, htmlText);
|
|
|
- htmlText = htmlText.stream().distinct().collect(Collectors.toList());
|
|
|
- commonAnalysisUtil.html2StructureMapNoColon(titles, htmlText, structureMap);
|
|
|
+ "填写时间", "主持科室小结(MDT的最终诊治决议)", "科主任(主持人)签名", "记录人(主管医师)签字", "日期");
|
|
|
+ htmlContent = commonAnalysisUtil.html2String(html);
|
|
|
+ if (StringUtil.isNotBlank(htmlContent)) {
|
|
|
+ htmlContent = htmlContent.replaceAll("[ ]", " ");
|
|
|
+ commonAnalysisUtil.html2StructureMap(titles, htmlContent, structureMap);
|
|
|
+ }
|
|
|
structureMap.put("rec_title=", recTitle);
|
|
|
break;
|
|
|
default:
|
|
|
- htmlText = commonAnalysisUtil.html2List(html, true);
|
|
|
- commonAnalysisUtil.html2StructureMap(titles, htmlText, structureMap);
|
|
|
+ htmlContent = commonAnalysisUtil.html2String(html);
|
|
|
+ if (StringUtil.isNotBlank(htmlContent)) {
|
|
|
+ htmlContent = htmlContent.replaceAll("[ ]", " ");
|
|
|
+ commonAnalysisUtil.html2StructureMap(titles, htmlContent, structureMap);
|
|
|
+ }
|
|
|
structureMap.put("rec_title=", "371");
|
|
|
break;
|
|
|
}
|