Bladeren bron

处理病案首页入参,添加病案首页规则

hujing 5 jaren geleden
bovenliggende
commit
7d9bfc4496
19 gewijzigde bestanden met toevoegingen van 213 en 19 verwijderingen
  1. 1 3
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0158.java
  2. 0 1
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0159.java
  3. 1 2
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0160.java
  4. 1 2
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0161.java
  5. 1 1
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0162.java
  6. 1 2
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0163.java
  7. 0 1
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0164.java
  8. 1 2
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0166.java
  9. 30 0
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0167.java
  10. 29 0
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0168.java
  11. 29 0
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0170.java
  12. 30 0
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0172.java
  13. 30 0
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0174.java
  14. 31 0
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0177.java
  15. 0 1
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0199.java
  16. 1 3
      kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0275.java
  17. 4 0
      trans/src/main/java/com/lantone/qc/trans/changx/ChangxDocTrans.java
  18. 23 0
      trans/src/main/java/com/lantone/qc/trans/changx/FirstPageRecordDocTrans.java
  19. 0 1
      trans/src/main/java/com/lantone/qc/trans/comsis/ModelDocGenerate.java

+ 1 - 3
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0158.java

@@ -5,7 +5,6 @@ import com.lantone.qc.kernel.util.CatalogueUtil;
 import com.lantone.qc.pub.Content;
 import com.lantone.qc.pub.model.InputInfo;
 import com.lantone.qc.pub.model.OutputInfo;
-import com.lantone.qc.pub.util.StringUtil;
 import org.springframework.stereotype.Component;
 
 import java.util.Map;
@@ -25,8 +24,7 @@ public class FIRP0158 extends QCCatalogue {
             Map<String, String> beHospitalStructureMap = inputInfo.getBeHospitalizedDoc().getStructureMap();
             String firstAdmissionName = firstpageStructureMap.get(Content.name).toString();
             String admissionName = beHospitalStructureMap.get(Content.name);
-            if (CatalogueUtil.removeSpecialChar(firstAdmissionName)
-                    .equals(CatalogueUtil.removeSpecialChar(admissionName))) {
+            if (CatalogueUtil.compareToken(firstAdmissionName,admissionName)) {
                 status = "0";
             }
         }

+ 0 - 1
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0159.java

@@ -5,7 +5,6 @@ import com.lantone.qc.kernel.util.CatalogueUtil;
 import com.lantone.qc.pub.Content;
 import com.lantone.qc.pub.model.InputInfo;
 import com.lantone.qc.pub.model.OutputInfo;
-import com.lantone.qc.pub.util.StringUtil;
 import org.springframework.stereotype.Component;
 
 import java.util.Map;

+ 1 - 2
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0160.java

@@ -24,8 +24,7 @@ public class FIRP0160 extends QCCatalogue {
             Map<String, String> beHospitalStructureMap = inputInfo.getBeHospitalizedDoc().getStructureMap();
             String firstAdmissionGender = firstpageStructureMap.get(Content.gender).toString();
             String admissionGender = beHospitalStructureMap.get(Content.gender);
-            if (CatalogueUtil.removeSpecialChar(firstAdmissionGender)
-                    .equals(CatalogueUtil.removeSpecialChar(admissionGender))) {
+            if (CatalogueUtil.compareToken(firstAdmissionGender,admissionGender)) {
                 status = "0";
             }
         }

+ 1 - 2
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0161.java

@@ -24,8 +24,7 @@ public class FIRP0161 extends QCCatalogue {
             Map<String, String> beHospitalStructureMap = inputInfo.getBeHospitalizedDoc().getStructureMap();
             String firstAdmissionAge = firstpageStructureMap.get(Content.age).toString();
             String admissionAge = beHospitalStructureMap.get(Content.age);
-            if (CatalogueUtil.removeSpecialChar(firstAdmissionAge)
-                    .equals(CatalogueUtil.removeSpecialChar(admissionAge))) {
+            if (CatalogueUtil.compareToken(firstAdmissionAge,admissionAge)) {
                 status = "0";
             }
         }

+ 1 - 1
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0162.java

@@ -20,7 +20,7 @@ public class FIRP0162 extends QCCatalogue {
     public void start(InputInfo inputInfo, OutputInfo outputInfo) {
         if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
             Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
-            String idcardInfo = firstpageStructureMap.get(Content.idcard_info).toString();
+            String idcardInfo = firstpageStructureMap.get(Content.idcardInfo).toString();
             if (!CatalogueUtil.isEmpty(idcardInfo)) {
                 String regex = "\\d{15}|\\d{17}[\\dxX]";
                 if (idcardInfo.matches(regex)) {

+ 1 - 2
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0163.java

@@ -5,7 +5,6 @@ import com.lantone.qc.kernel.util.CatalogueUtil;
 import com.lantone.qc.pub.Content;
 import com.lantone.qc.pub.model.InputInfo;
 import com.lantone.qc.pub.model.OutputInfo;
-import com.lantone.qc.pub.util.StringUtil;
 import org.springframework.stereotype.Component;
 
 import java.util.Map;
@@ -21,7 +20,7 @@ public class FIRP0163 extends QCCatalogue {
     public void start(InputInfo inputInfo, OutputInfo outputInfo) {
         if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
             Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
-            String idcardInfo = firstpageStructureMap.get(Content.idcard_info).toString();
+            String idcardInfo = firstpageStructureMap.get(Content.idcardInfo).toString();
             if (!CatalogueUtil.isEmpty(idcardInfo)){
                 status = "0";
             }

+ 0 - 1
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0164.java

@@ -5,7 +5,6 @@ import com.lantone.qc.kernel.util.CatalogueUtil;
 import com.lantone.qc.pub.Content;
 import com.lantone.qc.pub.model.InputInfo;
 import com.lantone.qc.pub.model.OutputInfo;
-import com.lantone.qc.pub.util.StringUtil;
 import org.springframework.stereotype.Component;
 
 import java.util.Map;

+ 1 - 2
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0166.java

@@ -24,8 +24,7 @@ public class FIRP0166 extends QCCatalogue {
             Map<String, String> beHospitalStructureMap = inputInfo.getBeHospitalizedDoc().getStructureMap();
             String firstAdmissionMarry = firstpageStructureMap.get(Content.marry).toString();
             String admissionMarry = beHospitalStructureMap.get(Content.marry);
-            if (CatalogueUtil.removeSpecialChar(firstAdmissionMarry)
-                    .equals(CatalogueUtil.removeSpecialChar(admissionMarry))) {
+            if (CatalogueUtil.compareToken(firstAdmissionMarry,admissionMarry)) {
                 status = "0";
             }
         }

+ 30 - 0
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0167.java

@@ -0,0 +1,30 @@
+package com.lantone.qc.kernel.catalogue.firstpagerecord;
+
+import com.lantone.qc.kernel.catalogue.QCCatalogue;
+import com.lantone.qc.kernel.util.CatalogueUtil;
+import com.lantone.qc.pub.Content;
+import com.lantone.qc.pub.model.InputInfo;
+import com.lantone.qc.pub.model.OutputInfo;
+import org.springframework.stereotype.Component;
+
+import java.util.Map;
+
+/**
+ * @ClassName : FIRP0167
+ * @Description : 联系人姓名一栏如果填入本人姓名,要提示出联系人应非本人,进行演示出来
+ * @Author : 胡敬
+ * @Date: 2020-03-16 11:02
+ */
+@Component
+public class FIRP0167 extends QCCatalogue {
+    public void start(InputInfo inputInfo, OutputInfo outputInfo) {
+        if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
+            Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
+            String name = firstpageStructureMap.get(Content.name).toString();
+            String contactName = firstpageStructureMap.get(Content.contactName).toString();
+            if (CatalogueUtil.compareToken(name,contactName)) {
+                status = "0";
+            }
+        }
+    }
+}

+ 29 - 0
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0168.java

@@ -0,0 +1,29 @@
+package com.lantone.qc.kernel.catalogue.firstpagerecord;
+
+import com.lantone.qc.kernel.catalogue.QCCatalogue;
+import com.lantone.qc.kernel.util.CatalogueUtil;
+import com.lantone.qc.pub.Content;
+import com.lantone.qc.pub.model.InputInfo;
+import com.lantone.qc.pub.model.OutputInfo;
+import org.springframework.stereotype.Component;
+
+import java.util.Map;
+
+/**
+ * @ClassName : FIRP0168
+ * @Description :入院途径未填写
+ * @Author : 胡敬
+ * @Date: 2020-03-16 11:30
+ */
+@Component
+public class FIRP0168 extends QCCatalogue {
+    public void start(InputInfo inputInfo, OutputInfo outputInfo) {
+        if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
+            Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
+            String admitPath = firstpageStructureMap.get(Content.admitPath).toString();
+            if (!CatalogueUtil.isEmpty(admitPath)){
+                status = "0";
+            }
+        }
+    }
+}

+ 29 - 0
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0170.java

@@ -0,0 +1,29 @@
+package com.lantone.qc.kernel.catalogue.firstpagerecord;
+
+import com.lantone.qc.kernel.catalogue.QCCatalogue;
+import com.lantone.qc.kernel.util.CatalogueUtil;
+import com.lantone.qc.pub.Content;
+import com.lantone.qc.pub.model.InputInfo;
+import com.lantone.qc.pub.model.OutputInfo;
+import org.springframework.stereotype.Component;
+
+import java.util.Map;
+
+/**
+ * @ClassName : FIRP0170
+ * @Description :转科科别未填写
+ * @Author : 胡敬
+ * @Date: 2020-03-16 11:33
+ */
+@Component
+public class FIRP0170 extends QCCatalogue {
+    public void start(InputInfo inputInfo, OutputInfo outputInfo) {
+        if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
+            Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
+            String transferDept = firstpageStructureMap.get(Content.transferDept).toString();
+            if (!CatalogueUtil.isEmpty(transferDept)){
+                status = "0";
+            }
+        }
+    }
+}

+ 30 - 0
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0172.java

@@ -0,0 +1,30 @@
+package com.lantone.qc.kernel.catalogue.firstpagerecord;
+
+import com.lantone.qc.kernel.catalogue.QCCatalogue;
+import com.lantone.qc.pub.Content;
+import com.lantone.qc.pub.model.InputInfo;
+import com.lantone.qc.pub.model.OutputInfo;
+import com.lantone.qc.pub.util.ListUtil;
+import org.springframework.stereotype.Component;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * @ClassName : FIRP0172
+ * @Description :门(急)诊诊断未填写
+ * @Author : 胡敬
+ * @Date: 2020-03-16 13:10
+ */
+@Component
+public class FIRP0172 extends QCCatalogue {
+    public void start(InputInfo inputInfo, OutputInfo outputInfo) {
+        if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
+            Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
+            List<Map<String, String>> outpatientEmergencyDiag = (List) firstpageStructureMap.get(Content.outpatientEmergencyDiag);
+            if (ListUtil.isNotEmpty(outpatientEmergencyDiag)) {
+                status = "0";
+            }
+        }
+    }
+}

+ 30 - 0
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0174.java

@@ -0,0 +1,30 @@
+package com.lantone.qc.kernel.catalogue.firstpagerecord;
+
+import com.lantone.qc.kernel.catalogue.QCCatalogue;
+import com.lantone.qc.pub.Content;
+import com.lantone.qc.pub.model.InputInfo;
+import com.lantone.qc.pub.model.OutputInfo;
+import com.lantone.qc.pub.util.ListUtil;
+import org.springframework.stereotype.Component;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * @ClassName : FIRP0174
+ * @Description :出院主要诊断未填
+ * @Author : 胡敬
+ * @Date: 2020-03-16 13:31
+ */
+@Component
+public class FIRP0174 extends QCCatalogue {
+    public void start(InputInfo inputInfo, OutputInfo outputInfo) {
+        if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
+            Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
+            List<Map<String, String>> outpatientEmergencyDiag = (List) firstpageStructureMap.get(Content.dischargeDiag);
+            if (ListUtil.isNotEmpty(outpatientEmergencyDiag)) {
+                status = "0";
+            }
+        }
+    }
+}

+ 31 - 0
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0177.java

@@ -0,0 +1,31 @@
+package com.lantone.qc.kernel.catalogue.firstpagerecord;
+
+import com.lantone.qc.kernel.catalogue.QCCatalogue;
+import com.lantone.qc.kernel.util.CatalogueUtil;
+import com.lantone.qc.pub.Content;
+import com.lantone.qc.pub.model.InputInfo;
+import com.lantone.qc.pub.model.OutputInfo;
+import com.lantone.qc.pub.util.ListUtil;
+import org.springframework.stereotype.Component;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * @ClassName : FIRP0177
+ * @Description :出院主诊断编码未填
+ * @Author : 胡敬
+ * @Date: 2020-03-16 14:01
+ */
+@Component
+public class FIRP0177 extends QCCatalogue {
+    public void start(InputInfo inputInfo, OutputInfo outputInfo) {
+        if (inputInfo.getFirstPageRecordDoc() != null && inputInfo.getFirstPageRecordDoc().getStructureMap() != null) {
+            Map<String, Object> firstpageStructureMap = inputInfo.getFirstPageRecordDoc().getStructureMap();
+            List<Map<String, String>> diagMapList = (List) firstpageStructureMap.get(Content.dischargeDiag);
+            if (ListUtil.isNotEmpty(diagMapList) && !CatalogueUtil.isEmpty(diagMapList.get(0).get(Content.diagCode))) {
+                status = "0";
+            }
+        }
+    }
+}

+ 0 - 1
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0199.java

@@ -5,7 +5,6 @@ import com.lantone.qc.kernel.util.CatalogueUtil;
 import com.lantone.qc.pub.Content;
 import com.lantone.qc.pub.model.InputInfo;
 import com.lantone.qc.pub.model.OutputInfo;
-import com.lantone.qc.pub.util.StringUtil;
 import org.springframework.stereotype.Component;
 
 import java.util.Map;

+ 1 - 3
kernel/src/main/java/com/lantone/qc/kernel/catalogue/firstpagerecord/FIRP0275.java

@@ -5,7 +5,6 @@ import com.lantone.qc.kernel.util.CatalogueUtil;
 import com.lantone.qc.pub.Content;
 import com.lantone.qc.pub.model.InputInfo;
 import com.lantone.qc.pub.model.OutputInfo;
-import com.lantone.qc.pub.util.StringUtil;
 import org.springframework.stereotype.Component;
 
 import java.util.Map;
@@ -25,8 +24,7 @@ public class FIRP0275 extends QCCatalogue {
             Map<String, String> leaveHospitalStructureMap = inputInfo.getLeaveHospitalDoc().getStructureMap();
             String firstDischargeTime = firstpageStructureMap.get(Content.actualStay).toString();//病案首页出院时间
             String dischargeTime = leaveHospitalStructureMap.get(Content.stayLength);//出院小结出院时间
-            if (StringUtil.isNotBlank(firstDischargeTime) && StringUtil.isNotBlank(dischargeTime)
-                    && firstDischargeTime.equals(dischargeTime)) {
+            if (CatalogueUtil.compareToken(firstDischargeTime, dischargeTime)) {
                 status = "0";
             }
         }

+ 4 - 0
trans/src/main/java/com/lantone/qc/trans/changx/ChangxDocTrans.java

@@ -25,6 +25,10 @@ public class ChangxDocTrans extends DocTrans {
                 beHospitalizedDocTrans.setModelDocGenerate(getModelDocGenerate());
                 inputInfo.setBeHospitalizedDoc(beHospitalizedDocTrans.extract(i));
             }
+            if (i.getTitle().equals("病案首页")) {
+                FirstPageRecordDocTrans firstPageRecordDocTrans = new FirstPageRecordDocTrans();
+                inputInfo.setFirstPageRecordDoc(firstPageRecordDocTrans.extract(i));
+            }
         }
         return inputInfo;
     }

+ 23 - 0
trans/src/main/java/com/lantone/qc/trans/changx/FirstPageRecordDocTrans.java

@@ -0,0 +1,23 @@
+package com.lantone.qc.trans.changx;
+
+import com.lantone.qc.pub.model.doc.FirstPageRecordDoc;
+import com.lantone.qc.pub.model.vo.MedrecVo;
+import com.lantone.qc.trans.ModelDocTrans;
+
+import java.util.Map;
+
+/**
+ * @Description: 入院记录文档生成
+ * @author: 胡敬
+ * @time: 2020/3/16 17:47
+ */
+public class FirstPageRecordDocTrans extends ModelDocTrans {
+
+    public FirstPageRecordDoc extract(MedrecVo medrecVo) {
+        Map<String,Object> content = medrecVo.getContent();
+        FirstPageRecordDoc firstPageRecordDoc = new FirstPageRecordDoc();
+        firstPageRecordDoc.setStructureMap(content);
+        return firstPageRecordDoc;
+    }
+
+}

+ 0 - 1
trans/src/main/java/com/lantone/qc/trans/comsis/ModelDocGenerate.java

@@ -104,5 +104,4 @@ public class ModelDocGenerate {
 
         return beHospitalizedDoc;
     }
-
 }