|
@@ -40,13 +40,13 @@ public class YiWuFirstCourseRecordDocTrans extends ModelDocTrans {
|
|
Map<String, String> sourceMap = YiWuXmlUtil.xmlToMap(content);
|
|
Map<String, String> sourceMap = YiWuXmlUtil.xmlToMap(content);
|
|
sourceMap.put("mode_id", ModuleMappingUtil.getDeptModuleId(modeId));
|
|
sourceMap.put("mode_id", ModuleMappingUtil.getDeptModuleId(modeId));
|
|
List<String> titles = Lists.newArrayList("病历记录时间", "一般情况","一、病例特点", "二、初步诊断", "三、诊断依据"
|
|
List<String> titles = Lists.newArrayList("病历记录时间", "一般情况","一、病例特点", "二、初步诊断", "三、诊断依据"
|
|
- , "四、鉴别诊断", "五、诊疗计划","主诊医师","记录医师");
|
|
|
|
|
|
+ , "四、鉴别诊断", "五、诊疗计划","记录医师");
|
|
String text = sourceMap.get("原始文本");
|
|
String text = sourceMap.get("原始文本");
|
|
- CommonAnalysisUtil.cutByTitles(text, titles, 0, sourceMap);
|
|
|
|
|
|
+ CommonAnalysisUtil.cutByTitlesNoColon(text, titles, 0, sourceMap);
|
|
//新生儿科特殊处理
|
|
//新生儿科特殊处理
|
|
- /*if (sourceMap.containsKey("病历记录时间")) {
|
|
|
|
|
|
+ if (StringUtils.isNotEmpty(sourceMap.get("病历记录时间"))&&sourceMap.get("病历记录时间").split("患者").length>1) {
|
|
sourceMap.put("病历内容", "患者" + sourceMap.get("病历记录时间").split("患者")[1]);
|
|
sourceMap.put("病历内容", "患者" + sourceMap.get("病历记录时间").split("患者")[1]);
|
|
- }*/
|
|
|
|
|
|
+ }
|
|
Map<String, String> changeKeyMap = Maps.newHashMap();
|
|
Map<String, String> changeKeyMap = Maps.newHashMap();
|
|
Iterator<Map.Entry<String, String>> it = sourceMap.entrySet().iterator();
|
|
Iterator<Map.Entry<String, String>> it = sourceMap.entrySet().iterator();
|
|
while (it.hasNext()) {
|
|
while (it.hasNext()) {
|
|
@@ -63,6 +63,41 @@ public class YiWuFirstCourseRecordDocTrans extends ModelDocTrans {
|
|
sourceMap.put("rec_title=" + contentMap.get("recTitle").toString(), "");
|
|
sourceMap.put("rec_title=" + contentMap.get("recTitle").toString(), "");
|
|
structureMap = OrdinaryAssistant.mapKeyContrast(sourceMap, keyContrasts, modeId);
|
|
structureMap = OrdinaryAssistant.mapKeyContrast(sourceMap, keyContrasts, modeId);
|
|
}
|
|
}
|
|
|
|
+ // 最后的主诊医师处理
|
|
|
|
+ //经主诊医师XXX同意后确定以下诊疗计划:......
|
|
|
|
+ //......。以下诊疗方案由主诊医师/诊疗组长XXX确认
|
|
|
|
+ if(StringUtils.isNotEmpty(structureMap.get("诊疗计划"))){
|
|
|
|
+ if(structureMap.get("诊疗计划").contains("诊疗方案")){
|
|
|
|
+ String temp=structureMap.get("诊疗计划");
|
|
|
|
+ List<String> titles = Lists.newArrayList("。",";");
|
|
|
|
+ for (String str: titles) {
|
|
|
|
+ String[] s=temp.split(str);
|
|
|
|
+ temp=s[s.length-1];
|
|
|
|
+ }
|
|
|
|
+ List<String> titles1 = Lists.newArrayList("方案","由","组长","医师","主诊","诊疗","确认");
|
|
|
|
+ for (String str:titles1) {
|
|
|
|
+ temp=temp.replaceAll(str,"");
|
|
|
|
+ }
|
|
|
|
+ structureMap.put("主诊医师",temp);
|
|
|
|
+ structureMap.put("诊疗计划",structureMap.get("诊疗计划").split("诊疗方案")[0]);
|
|
|
|
+ }
|
|
|
|
+ if(structureMap.get("诊疗计划").contains("诊疗计划")){
|
|
|
|
+ String temp=structureMap.get("诊疗计划");
|
|
|
|
+ List<String> titles = Lists.newArrayList("。",";",":");
|
|
|
|
+ for (String str: titles) {
|
|
|
|
+ String[] s=temp.split(str);
|
|
|
|
+ temp=s[0];
|
|
|
|
+ }
|
|
|
|
+ List<String> titles1 = Lists.newArrayList("经","主诊","同意后","医师","确定","以下","诊疗计划");
|
|
|
|
+ for (String str:titles1) {
|
|
|
|
+ temp=temp.replaceAll(str,"");
|
|
|
|
+ }
|
|
|
|
+ structureMap.put("主诊医师",temp);
|
|
|
|
+ if(structureMap.get("诊疗计划").split(":").length>1){
|
|
|
|
+ structureMap.put("诊疗计划",structureMap.get("诊疗计划").split(":")[1]);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
// 病例特点=主诉+现病史-发病情况+专科检查+实验室检查+影像学检查+辅助检查结果+呼吸+脉搏+体温+血压
|
|
// 病例特点=主诉+现病史-发病情况+专科检查+实验室检查+影像学检查+辅助检查结果+呼吸+脉搏+体温+血压
|
|
// structureMap.put("病例特点", MapUtil.getSelectString(structureMap, Arrays.asList(
|
|
// structureMap.put("病例特点", MapUtil.getSelectString(structureMap, Arrays.asList(
|
|
// "主诉",
|
|
// "主诉",
|
|
@@ -106,23 +141,6 @@ public class YiWuFirstCourseRecordDocTrans extends ModelDocTrans {
|
|
List<String> keys = Lists.newArrayList("检查计划", "治疗计划", "诊疗计划");
|
|
List<String> keys = Lists.newArrayList("检查计划", "治疗计划", "诊疗计划");
|
|
String treatPlanJoin = structureMapJoin(structureMap, keys);
|
|
String treatPlanJoin = structureMapJoin(structureMap, keys);
|
|
firstCourseRecordDoc.getTreatPlanLabel().setAiText(treatPlanJoin);
|
|
firstCourseRecordDoc.getTreatPlanLabel().setAiText(treatPlanJoin);
|
|
- // 最后的主诊医师处理
|
|
|
|
- if(structureMap.containsKey("诊疗计划")){
|
|
|
|
- if(StringUtils.isNotEmpty(structureMap.get("诊疗计划"))){
|
|
|
|
- String temp=structureMap.get("诊疗计划");
|
|
|
|
- List<String> titles = Lists.newArrayList("。",";");
|
|
|
|
- for (String str: titles) {
|
|
|
|
- String[] s=temp.split(str);
|
|
|
|
- temp=s[s.length-1];
|
|
|
|
- }
|
|
|
|
- List<String> titles1 = Lists.newArrayList("方案","由","组长","医师","主诊","诊疗","确认");
|
|
|
|
- for (String str:titles1) {
|
|
|
|
- temp=temp.replaceAll(str,"");
|
|
|
|
- }
|
|
|
|
- structureMap.put("主诊医师",temp);
|
|
|
|
- structureMap.put("诊疗计划",structureMap.get("诊疗计划").split("诊疗方案")[0]);
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
return firstCourseRecordDoc;
|
|
return firstCourseRecordDoc;
|
|
}
|
|
}
|
|
|
|
|