소스 검색

检验信息展示兼容邵逸夫和长兴数据

chengyao 4 년 전
부모
커밋
09f434556e

+ 1 - 1
src/main/java/com/diagbot/facade/ConsoleExportFacade.java

@@ -67,7 +67,7 @@ public class ConsoleExportFacade {
     }
 
     /**
-     * 运行病历稽查统计导出(首页)
+     * 病历稽查统计导出(首页)
      *
      * @param filterVO
      * @return

+ 4 - 2
src/main/java/com/diagbot/service/impl/MedLisInfoServiceImpl.java

@@ -58,8 +58,10 @@ public class MedLisInfoServiceImpl extends ServiceImpl<MedLisInfoMapper, MedLisI
         Date leaveHospitalDate = (Date) timeMap.get("leave_hospital_date");
         examineInfoVO.setLeaveHospitalDate(leaveHospitalDate);
 
-        String s = examineInfoVO.getBehospitalCode();
-        examineInfoVO.setBehospitalCode(s.split("_")[0]);
+        String behospitalCode = examineInfoVO.getBehospitalCode();
+        if(2l == examineInfoVO.getHospitalId()){
+            examineInfoVO.setBehospitalCode(behospitalCode.split("_")[0]);
+        }
 
         IPage<ExamineInfoDTO> page = this.baseMapper.getExamineInfo(examineInfoVO, infoSet);
         return page;

+ 4 - 4
src/main/java/com/diagbot/service/impl/MedPacsInfoServiceImpl.java

@@ -9,6 +9,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.diagbot.vo.CheckInfoVO;
 import org.springframework.stereotype.Service;
 
+import javax.validation.constraints.NotBlank;
 import java.util.*;
 
 /**
@@ -52,10 +53,9 @@ public class MedPacsInfoServiceImpl extends ServiceImpl<MedPacsInfoMapper, MedPa
             Date leaveHospitalDate = (Date) timeMap.get("leave_hospital_date");
             checkInfoVO.setLeaveHospitalDate(leaveHospitalDate);
         }
-        //邵逸夫病历号处理
-        if("2".equals(checkInfoVO.getHospitalId())){
-            String s = checkInfoVO.getBehospitalCode();
-            checkInfoVO.setBehospitalCode(s.split("_")[0]);
+        String behospitalCode = checkInfoVO.getBehospitalCode();
+        if(2l == checkInfoVO.getHospitalId()){
+            checkInfoVO.setBehospitalCode(behospitalCode.split("_")[0]);
         }
 
         IPage<CheckInfoDTO> page = this.baseMapper.getCheckInfo(checkInfoVO, infoSet);

+ 6 - 1
src/main/resources/mapper/MedLisInfoMapper.xml

@@ -73,7 +73,12 @@
         AND t1.hospital_id = t2.hospital_id
         and t1.hospital_id = t3.hospital_id
         AND t1.behospital_code = t2.behospital_code
-        and t1.behospital_code = t3.file_code
+        <if test="examineInfoVO.hospitalId != null and examineInfoVO.hospitalId == 1l">
+            and t1.behospital_code = t3.behospital_code
+        </if>
+        <if test="examineInfoVO.hospitalId != null and examineInfoVO.hospitalId == 2l">
+            and t1.behospital_code = t3.file_code
+        </if>
         AND t1.rep_no = t2.rep_no
         <if test="examineInfoVO.hospitalId != null">
             and t1.hospital_id = #{examineInfoVO.hospitalId}

+ 6 - 1
src/main/resources/mapper/MedPacsInfoMapper.xml

@@ -65,7 +65,12 @@
         and t1.hospital_id = t2.hospital_id
         and t1.hospital_id = t3.hospital_id
         and t1.behospital_code = t2.behospital_code
-        and t1.behospital_code = t3.file_code
+        <if test="checkInfoVO.hospitalId != null and checkInfoVO.hospitalId == 1l">
+            and t1.behospital_code = t3.behospital_code
+        </if>
+        <if test="checkInfoVO.hospitalId != null and checkInfoVO.hospitalId == 2l">
+            and t1.behospital_code = t3.file_code
+        </if>
         and t1.rep_no = t2.rep_no
         <if test="checkInfoVO.hospitalId != null">
             and t1.hospital_id = #{checkInfoVO.hospitalId}