|
@@ -32,31 +32,33 @@ public class ChangxFirstCourseRecordDocTrans extends ModelDocTrans {
|
|
if (index == sourceTitle.length() - 1) {
|
|
if (index == sourceTitle.length() - 1) {
|
|
targetTitle += sourceTitle.substring(index, index + 1);
|
|
targetTitle += sourceTitle.substring(index, index + 1);
|
|
} else {
|
|
} else {
|
|
- targetTitle += sourceTitle.substring(index, index + 1) + "[\\s]*";
|
|
|
|
|
|
+ targetTitle += sourceTitle.substring(index, index + 1) + "[\\s\\p{Zs}]*";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
targetTitles.add(targetTitle);
|
|
targetTitles.add(targetTitle);
|
|
});
|
|
});
|
|
|
|
|
|
Map<String, String> sourceMap = Preproc.extract_doc_pub(false, targetTitles, content);
|
|
Map<String, String> sourceMap = Preproc.extract_doc_pub(false, targetTitles, content);
|
|
|
|
+ sourceMap.put("病程记录内容",
|
|
|
|
+ sourceMap.get("病程记录内容")
|
|
|
|
+ .replace(sourceMap.get("病程记录时间"), "")
|
|
|
|
+ .replace(sourceMap.get("病程记录名称"), "")
|
|
|
|
+ );
|
|
|
|
+
|
|
Map<String, String> targetMap = Maps.newHashMap();
|
|
Map<String, String> targetMap = Maps.newHashMap();
|
|
|
|
+ Map<String, Object> pageData = Maps.newHashMap();
|
|
for (String key : sourceMap.keySet()) {
|
|
for (String key : sourceMap.keySet()) {
|
|
if (key.equals("病程记录时间")) {
|
|
if (key.equals("病程记录时间")) {
|
|
targetMap.put("记录时间", sourceMap.get(key));
|
|
targetMap.put("记录时间", sourceMap.get(key));
|
|
} else {
|
|
} else {
|
|
- targetMap.put(key.replaceAll("[一二三四五六七八九十][、.]|\\s", ""), sourceMap.get(key));
|
|
|
|
|
|
+ targetMap.put(key.replaceAll("[一二三四五六七八九十][、.]", ""), sourceMap.get(key));
|
|
}
|
|
}
|
|
|
|
+ pageData.put(key.replaceAll("[一二三四五六七八九十][、.]", ""), sourceMap.get(key));
|
|
}
|
|
}
|
|
|
|
|
|
- sourceMap.put("病程记录内容",
|
|
|
|
- sourceMap.get("病程记录内容")
|
|
|
|
- .replace(sourceMap.get("病程记录时间"), "")
|
|
|
|
- .replace(sourceMap.get("病程记录名称"), "")
|
|
|
|
- );
|
|
|
|
-
|
|
|
|
FirstCourseRecordDoc firstCourseRecordDoc = ModelDocGenerate.firstCourseRecordDocGen(targetMap);
|
|
FirstCourseRecordDoc firstCourseRecordDoc = ModelDocGenerate.firstCourseRecordDocGen(targetMap);
|
|
firstCourseRecordDoc.setText(content);
|
|
firstCourseRecordDoc.setText(content);
|
|
- firstCourseRecordDoc.setPageData((Map) sourceMap);
|
|
|
|
|
|
+ firstCourseRecordDoc.setPageData(pageData);
|
|
|
|
|
|
return firstCourseRecordDoc;
|
|
return firstCourseRecordDoc;
|
|
}
|
|
}
|