Prechádzať zdrojové kódy

义乌不能评分bug修改

hujing 4 rokov pred
rodič
commit
53af656924

+ 3 - 2
kernel/src/main/java/com/lantone/qc/kernel/structure/ai/FirstCourseRecordAI.java

@@ -105,11 +105,12 @@ public class FirstCourseRecordAI extends ModelAI {
              */
 
             //病历特点与现病史比较相似度
-            if (inputInfo.getBeHospitalizedDoc() != null && StringUtil.isNotBlank(inputInfo.getBeHospitalizedDoc().getPresentLabel().getText())) {
+            if (inputInfo.getBeHospitalizedDoc() != null) {
                 //先从结构化数据找病例特点
                 if (StringUtil.isNotBlank(structureMap.get("现病史")) && inputInfo.getBeHospitalizedDoc().getPresentLabel() != null) {
                     putContent(similarContent, structureMap.get("现病史"), inputInfo.getBeHospitalizedDoc().getPresentLabel().getText());
-                } else if (firstCourseRecordDoc.getCaseCharacteristicLabel() != null && StringUtil.isNotBlank(firstCourseRecordDoc.getCaseCharacteristicLabel().getText())) {
+                } else if (firstCourseRecordDoc.getCaseCharacteristicLabel() != null && StringUtil.isNotBlank(firstCourseRecordDoc.getCaseCharacteristicLabel().getText())
+                        && inputInfo.getBeHospitalizedDoc().getPresentLabel() != null) {
                     //再从doc找病例特点
                     putContent(similarContent, firstCourseRecordDoc.getCaseCharacteristicLabel().getText(), inputInfo.getBeHospitalizedDoc().getPresentLabel().getText());
                 }

+ 1 - 0
public/src/main/java/com/lantone/qc/pub/Content.java

@@ -271,6 +271,7 @@ public class Content {
             "yyyy年M月d日H时m分",
             "yyyy-MM-ddHH:mm:ss",
             "yyyy-MM-ddHH:mm",
+            "yyyy-MM-ddHH:mm",
             "yyyy-MM-ddHH:m",
             "yyyy-MM-ddH:mm",
             "yyyy-MM-ddH:m",

+ 24 - 36
trans/src/main/java/com/lantone/qc/trans/yiwu/YiWuBeHospitalizedDocTrans.java

@@ -5,7 +5,17 @@ import com.lantone.qc.dbanaly.facade.yiwu.YiWuXmlUtil;
 import com.lantone.qc.dbanaly.util.ModuleMappingUtil;
 import com.lantone.qc.dbanaly.util.SpecialStorageUtil;
 import com.lantone.qc.pub.model.doc.BeHospitalizedDoc;
-import com.lantone.qc.pub.model.label.*;
+import com.lantone.qc.pub.model.label.ChiefLabel;
+import com.lantone.qc.pub.model.label.DiagLabel;
+import com.lantone.qc.pub.model.label.FamilyLabel;
+import com.lantone.qc.pub.model.label.MaritalLabel;
+import com.lantone.qc.pub.model.label.MenstrualLabel;
+import com.lantone.qc.pub.model.label.PacsLabel;
+import com.lantone.qc.pub.model.label.PastLabel;
+import com.lantone.qc.pub.model.label.PersonalLabel;
+import com.lantone.qc.pub.model.label.PresentLabel;
+import com.lantone.qc.pub.model.label.VitalLabel;
+import com.lantone.qc.pub.model.label.VitalLabelSpecial;
 import com.lantone.qc.pub.model.vo.BehospitalInfoVO;
 import com.lantone.qc.pub.model.vo.MedrecVo;
 import com.lantone.qc.pub.util.FastJsonUtils;
@@ -50,7 +60,7 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
                 dailyTrans(sourceMap, text, behDeptId);
             } else {
                 List<String> titles = Lists.newArrayList("婚    姻", "婚姻状况", "住      址", "供 史 者", "性      别", "婚  姻", "民  族", "民    族", "个人史", "妇科检查", "产科检查",
-                        "实验室", "初步诊断", "修正诊断", "补充诊断", "初步诊断医师", "修正诊断医师", "补充诊断医师", "初步诊断日期", "修正诊断日期", "补充诊断日期", "诊断和诊断修正","婚 育 史","家 族 史","体格检查(一)","现 病 史","既 往 史","系统回顾");
+                        "实验室", "初步诊断", "修正诊断", "补充诊断", "初步诊断医师", "修正诊断医师", "补充诊断医师", "初步诊断日期", "修正诊断日期", "补充诊断日期", "诊断和诊断修正", "婚 育 史", "家 族 史", "体格检查(一)", "现 病 史", "既 往 史", "系统回顾");
                 List<String> modifyKey = Lists.newArrayList("初步诊断", "修正诊断", "补充诊断");
                 List<String> sortTitles = CommonAnalysisUtil.sortTitlesNoColon(modifyKey, text);
                 for (String key : sortTitles) {
@@ -108,17 +118,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
             String value = structureMap.get("姓名").split(" ")[0];
             structureMap.put("姓名", value);
         }
-        //日间病历拼接入院情况
-        if (structureMap.containsKey("现病史") && structureMap.containsKey("既往史")) {
-            structureMap.put("入院情况", structureMap.get("现病史") + structureMap.get("既往史"));
-        } else if (structureMap.containsKey("现病史")) {
-            structureMap.put("入院情况", structureMap.get("现病史"));
-        } else if (structureMap.containsKey("既往史")) {
-            structureMap.put("入院情况", structureMap.get("既往史"));
-        }
-        if (structureMap.containsKey("辅助检查") && structureMap.containsKey("特殊检查")) {
-            structureMap.put("辅助检查", structureMap.get("辅助检查") + "\n" + structureMap.get("特殊检查"));
-        }
         //如果有入院时间,优先使用
         addKeyMapping(structureMap, "入院时间", "入病房时间");
         //如果有职业,优先使用
@@ -178,7 +177,7 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
             "联系地址=户口地址",
             "患者工作单位名称=户口地址",
             "出生日期时间=出生日期",
-//            "医生签名=初步诊断医师签名",
+            //            "医生签名=初步诊断医师签名",
             "签字日期=初步诊断日期",
             "供史者=病史陈述者",
             "无痛人流主诉=主诉",
@@ -194,7 +193,7 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
             "有/无=产前检查",
             "末次月经日期=末次月经",
             "入院诊断1=入院诊断",
-//            "记录医师=初步诊断医师签名",
+            //            "记录医师=初步诊断医师签名",
             "修正诊断签名日期=修正诊断日期",
             "修正诊断一医师签名=修正诊断医师签名",
             "患者姓名=姓名",
@@ -237,25 +236,24 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("主诉"))) {
             beHospitalizedDoc.setChiefLabel(null);
         }
-        //        structureMap.remove("主诉");
 
         // 走模型
         PresentLabel presentLabel = new PresentLabel();
-        presentLabel.setText(structureMap.get("现病史"));
-        beHospitalizedDoc.setPresentLabel(presentLabel);
-        if (StringUtil.isBlank(structureMap.get("现病史"))) {
-            beHospitalizedDoc.setPresentLabel(null);
+        if (StringUtil.isNotBlank(structureMap.get("现病史"))) {
+            presentLabel.setText(structureMap.get("现病史"));
+        } else if (StringUtil.isNotBlank(structureMap.get("入院情况"))) {
+            presentLabel.setText(structureMap.get("入院情况"));
         }
-        //        structureMap.remove("现病史");
+        beHospitalizedDoc.setPresentLabel(presentLabel);
 
         PastLabel pastLabel = new PastLabel();
         pastLabel.setCrfLabel(false);
-        pastLabel.setText(structureMap.get("既往史"));
-        beHospitalizedDoc.setPastLabel(pastLabel);
-        if (StringUtil.isBlank(structureMap.get("既往史"))) {
-            beHospitalizedDoc.setPastLabel(null);
+        if (StringUtil.isNotBlank(structureMap.get("既往史"))) {
+            presentLabel.setText(structureMap.get("既往史"));
+        } else if (StringUtil.isNotBlank(structureMap.get("入院情况"))) {
+            presentLabel.setText(structureMap.get("入院情况"));
         }
-        //        structureMap.remove("既往史");
+        beHospitalizedDoc.setPastLabel(pastLabel);
 
         PersonalLabel personalLabel = new PersonalLabel();
         //        personalLabel.setCrfLabel(false);
@@ -264,7 +262,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("个人史"))) {
             beHospitalizedDoc.setPersonalLabel(null);
         }
-        //        structureMap.remove("个人史");
 
         MaritalLabel maritalLabel = new MaritalLabel();
         //        maritalLabel.setCrfLabel(false);
@@ -273,7 +270,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("婚育史"))) {
             beHospitalizedDoc.setMaritalLabel(null);
         }
-        //        structureMap.remove("婚育史");
 
         MenstrualLabel menstrualLabel = new MenstrualLabel();
         //        menstrualLabel.setCrfLabel(false);
@@ -282,7 +278,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("月经史"))) {
             beHospitalizedDoc.setMenstrualLabel(null);
         }
-        //        structureMap.remove("月经史");
 
         FamilyLabel familyLabel = new FamilyLabel();
         //        familyLabel.setCrfLabel(false);
@@ -291,7 +286,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("家族史"))) {
             beHospitalizedDoc.setFamilyLabel(null);
         }
-        //        structureMap.remove("家族史");
 
         VitalLabel vitalLabel = new VitalLabel();
         //        vitalLabel.setCrfLabel(false);
@@ -300,7 +294,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("体格检查"))) {
             beHospitalizedDoc.setVitalLabel(null);
         }
-        //        structureMap.remove("体格检查");
 
         VitalLabelSpecial vitalLabelSpecial = new VitalLabelSpecial();
         //        vitalLabelSpecial.setCrfLabel(false);
@@ -309,7 +302,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("专科体格检查"))) {
             beHospitalizedDoc.setVitalLabelSpecial(null);
         }
-        //        structureMap.remove("专科体格检查");
 
         // 走模型
         PacsLabel pacsLabel = new PacsLabel();
@@ -319,7 +311,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("辅助检查"))) {
             beHospitalizedDoc.setPacsLabel(null);
         }
-        //        structureMap.remove("辅助检查");
 
         // 走模型
         DiagLabel initialDiagLabel = new DiagLabel();
@@ -328,7 +319,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("初步诊断"))) {
             beHospitalizedDoc.setInitialDiagLabel(null);
         }
-        //        structureMap.remove("初步诊断");
 
         // 走模型
         DiagLabel revisedDiagLabel = new DiagLabel();
@@ -337,7 +327,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("修正诊断"))) {
             beHospitalizedDoc.setRevisedDiagLabel(null);
         }
-        //        structureMap.remove("修正诊断");
 
         // 走模型
         DiagLabel suppleDiagLabel = new DiagLabel();
@@ -346,7 +335,6 @@ public class YiWuBeHospitalizedDocTrans extends ModelDocTrans {
         if (StringUtil.isBlank(structureMap.get("补充诊断"))) {
             beHospitalizedDoc.setSuppleDiagLabel(null);
         }
-        //        structureMap.remove("补充诊断");
 
         beHospitalizedDoc.setStructureMap(structureMap);