|
@@ -111,6 +111,10 @@ public class FirstCourseRecordTran extends TargetTran {
|
|
}
|
|
}
|
|
if(StringUtil.isNotEmpty(retMap.get("病例特点"))) {
|
|
if(StringUtil.isNotEmpty(retMap.get("病例特点"))) {
|
|
String specical = retMap.get("病例特点");
|
|
String specical = retMap.get("病例特点");
|
|
|
|
+ String flagName = "因“";
|
|
|
|
+ if (specical.contains(flagName)) {
|
|
|
|
+ specical = specical.substring(specical.indexOf(flagName));
|
|
|
|
+ }
|
|
String retStr = "";
|
|
String retStr = "";
|
|
if (specical.contains("“")) {
|
|
if (specical.contains("“")) {
|
|
String[] split = specical.split("“");
|
|
String[] split = specical.split("“");
|
|
@@ -132,19 +136,27 @@ public class FirstCourseRecordTran extends TargetTran {
|
|
|
|
|
|
if(text.contains("诊疗计划:")){
|
|
if(text.contains("诊疗计划:")){
|
|
String str = text.substring(text.lastIndexOf("诊疗计划:") + "诊疗计划:".length());
|
|
String str = text.substring(text.lastIndexOf("诊疗计划:") + "诊疗计划:".length());
|
|
|
|
+ String flagName = "";
|
|
if(str.contains("\n")){
|
|
if(str.contains("\n")){
|
|
String[] split = str.split("\n");
|
|
String[] split = str.split("\n");
|
|
for (int i = 0; i < split.length; i++) {
|
|
for (int i = 0; i < split.length; i++) {
|
|
if(split[i].contains("/") && split[i].length()<=15){
|
|
if(split[i].contains("/") && split[i].length()<=15){
|
|
- str = str.substring(0,str.lastIndexOf(split[i]));
|
|
|
|
- retMap.put("诊疗计划",str);
|
|
|
|
|
|
+ flagName = split[i];
|
|
}else{
|
|
}else{
|
|
String date = extractDate(split[i]);
|
|
String date = extractDate(split[i]);
|
|
if(StringUtil.isNotEmpty(date)){
|
|
if(StringUtil.isNotEmpty(date)){
|
|
- str = str.substring(0, str.indexOf(date));
|
|
|
|
- retMap.put("诊疗计划",str);
|
|
|
|
|
|
+ flagName = split[i];
|
|
|
|
+ }else{
|
|
|
|
+ if(split[i].contains("年") && split[i].contains("月")&& split[i].contains("日")){
|
|
|
|
+ flagName = split[i];
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ String plan = retMap.get("诊疗计划");
|
|
|
|
+ if(StringUtil.isNotEmpty(flagName) && plan.contains(flagName)){
|
|
|
|
+ plan = plan.substring(0, plan.lastIndexOf(flagName));
|
|
|
|
+ retMap.put("诊疗计划",plan);
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -163,6 +175,10 @@ public class FirstCourseRecordTran extends TargetTran {
|
|
String[] splits = split[i].split(":");
|
|
String[] splits = split[i].split(":");
|
|
sb.append(splits[0]);
|
|
sb.append(splits[0]);
|
|
flag = false;
|
|
flag = false;
|
|
|
|
+ }else if(split[i].contains(":")){
|
|
|
|
+ String[] splits = split[i].split(":");
|
|
|
|
+ sb.append(splits[0]);
|
|
|
|
+ flag = false;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -173,8 +189,8 @@ public class FirstCourseRecordTran extends TargetTran {
|
|
if(flag){
|
|
if(flag){
|
|
String firStr = retMap.get("鉴别诊断");
|
|
String firStr = retMap.get("鉴别诊断");
|
|
retMap.put("鉴别诊断-西医诊断名称",firStr);
|
|
retMap.put("鉴别诊断-西医诊断名称",firStr);
|
|
- retMap.remove("鉴别诊断");
|
|
|
|
}
|
|
}
|
|
|
|
+ retMap.remove("鉴别诊断");
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|