Parcourir la source

门诊发药查看门诊历史处方问题修复

hsh il y a 1 an
Parent
commit
a8e62cf0e6

+ 5 - 0
src/main/java/cn/hnthyy/thmz/controller/mz/MzBlRecordController.java

@@ -161,6 +161,11 @@ public class MzBlRecordController {
                 //}
                 if (mzBlRecord.getPatientId() != null && StringUtils.isNotBlank(mzBlRecord.getPatientId())) {
                     List<MzPatientMi> mzPatientMiList = mzPatientMiService.queryByCommonParams(mzBlRecord.getPatientId());
+                    if(mzBlRecord.getTimes() != null && mzBlRecord.getTimes() == -1){
+                        // 发药查询门诊历史病历需要根据病人id精确查找
+                        mzPatientMiList = mzPatientMiList.stream().filter(p -> p.getPatientId().equals(mzBlRecord.getPatientId())).collect(Collectors.toList());
+                        mzBlRecord.setTimes(null);
+                    }
                     if (mzPatientMiList != null && mzPatientMiList.size() > 0) {
                         List<String> patientIds = mzPatientMiList.stream().map(m -> m.getPatientId()).collect(Collectors.toList());
                         if (patientIds != null && patientIds.size() > 0) {

+ 1 - 0
src/main/resources/static/js/mz/west_pharmacy_send.js

@@ -1995,6 +1995,7 @@ function queryDataS(params) {
     var rePortRangeArr = getRePortRangeArr1();
     var temp = {   //这里的键的名字和控制器的变量名必须一直,这边改动,控制器也需要改成一样的
         patientId: coreId,
+        times: '-1', // 这里需要根据patientId精确查找病人的病历,而不是模糊查询
         beginTime: rePortRangeArr[0],
         endTime: rePortRangeArr[1],
         pageSize: params.limit,   //页面大小