Explorar el Código

义乌妇保规则更新-主治医师48小时、主任医师72h、查房记录孕产期和入院记录婚孕史相关规则优化

“wangdsYun hace 4 meses
padre
commit
2d11eb0083

+ 5 - 1
kernel/src/main/java/com/lantone/qc/kernel/catalogue/hospital/yiwu/threelevelward/THR0125.java

@@ -20,7 +20,7 @@ import java.util.Map;
 
 /**
  * @ClassName : THR0125
- * @Description : 副主任医师/主任医师查房首次查房记录未在                       患者入院72h内完成
+ * @Description : 副主任医师/主任医师查房首次查房记录未在患者入院72h内完成
  * @Author : 胡敬
  * @Date: 2020-03-19 13:51
  */
@@ -110,6 +110,10 @@ public class THR0125 extends QCCatalogue {
                 if (!CatalogueUtil.compareTime(StringUtil.parseDateTime(admisTime), StringUtil.parseDateTime(wardDateStr), 72 * 60L)) {
                     String makeTitle = structureMap.get("查房标题");
                     String pathography = structureMap.get("病情记录");
+                    if ("主任".equals(pathography)){
+                        status.set("0");
+                        return;
+                    }
                     //判断标题
                     visitingPhysicianHouse(operatorName, makeTitle);
                     //判断病情记录

+ 8 - 6
kernel/src/main/java/com/lantone/qc/kernel/catalogue/hospital/yiwu/threelevelward/THR0126.java

@@ -135,12 +135,14 @@ public class THR0126 extends QCCatalogue {
             Map<String, String> structureMap = threeLevelWard.getStructureMap();
             String wardDateStr = structureMap.get("查房日期");
             if (!CatalogueUtil.compareTime(StringUtil.parseDateTime(admisTime), StringUtil.parseDateTime(wardDateStr), 48 * 60L)) {
-                String makeTitle = structureMap.get("查房标题");
-                String pathography = structureMap.get("病情记录");
-                //判断标题
-                visitingPhysicianHouse(operatorName, makeTitle);
-                //判断病情记录
-                visitingPhysicianHouse(operatorName, pathography);
+                status.set("0");
+                return;
+//                String makeTitle = structureMap.get("查房标题");
+//                String pathography = structureMap.get("病情记录");
+//                //判断标题
+//                visitingPhysicianHouse(operatorName, makeTitle);
+//                //判断病情记录
+//                visitingPhysicianHouse(operatorName, pathography);
             }
         }
     }

+ 28 - 21
kernel/src/main/java/com/lantone/qc/kernel/catalogue/threelevelward/THR03325.java

@@ -47,6 +47,27 @@ public class THR03325 extends QCCatalogue {
         if (beHospitalizedDoc == null || threeLevelWardDocs == null) {
             return;
         }
+        //获取入院记录婚育史中孕产次
+        String PPT = "";
+        //获取婚育史
+        Map<String, String> MaritalStructureMap = beHospitalizedDoc.getStructureMap();
+        if (MaritalStructureMap == null) {
+            return;
+        }
+
+        String marital = MaritalStructureMap.get("婚育史");
+        if (StringUtil.isBlank(marital)) {
+            return;
+        }
+        Pattern p = Pattern.compile("([0-9])-([0-9])-([0-9])-([0-9])");
+        Matcher matcherMarital = p.matcher(marital);
+        if (matcherMarital.find()) {
+            PPT = matcherMarital.group();
+        }
+        if (StringUtil.isEmpty(PPT)) {
+            return;
+        }
+
         //创建存储能匹配疾病的集合
         List<String> diagList = new ArrayList<>();
         //存放孕次A
@@ -59,6 +80,12 @@ public class THR03325 extends QCCatalogue {
         for (ThreeLevelWardDoc threeLevelWard : allDoctorWradDocs) {
             Map<String, String> structureMap = threeLevelWard.getStructureMap();
             String record = structureMap.get("病情记录");
+            if (StringUtil.isEmpty(record)) {
+                continue;
+            }
+            if (record.contains(PPT)) {
+                return;
+            }
             Pattern pattern = Pattern.compile(".*[Gg孕][^1-9]?([1-9])[^1-9]?[Pp产][^1-9]?([0-9])[^1-9].*");
             Matcher matcher = pattern.matcher(record);
             if (matcher.find()) {
@@ -81,27 +108,6 @@ public class THR03325 extends QCCatalogue {
             return;
         }
 
-        //获取入院记录婚育史中孕产次
-        String PPT = "";
-        //获取婚育史
-        MaritalLabel maritalLabel = beHospitalizedDoc.getMaritalLabel();
-        if (maritalLabel == null) {
-            return;
-        }
-
-        Fertility fertility = maritalLabel.getFertility();
-        if (fertility == null) {
-            return;
-        }
-        String name = fertility.getName();
-        Pattern p = Pattern.compile("([0-9])-([0-9])-([0-9])-([0-9])");
-        Matcher matcher = p.matcher(name);
-        if (matcher.find()) {
-            PPT = matcher.group();
-        }
-        if (StringUtil.isEmpty(PPT)) {
-            return;
-        }
         //[孕次A】==a+b+c+1,且【产次B】==a+b+c
         String[] split = PPT.split("-");
         try {
@@ -120,4 +126,5 @@ public class THR03325 extends QCCatalogue {
     private int strConvertInt(String str) {
         return Integer.parseInt(str);
     }
+
 }