From 19ac309ff5f33c95377fc6e7568c26a780ebfbd6 Mon Sep 17 00:00:00 2001 From: zhangheng <3226558941@qq.com> Date: Mon, 6 Jan 2025 17:04:18 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=BC=E5=85=A5=E5=BD=93=E6=9C=88=E5=A4=84?= =?UTF-8?q?=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/PatientInfoServiceImpl.java | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/postdischarge-manage/src/main/java/com/xinelu/manage/service/patientinfo/impl/PatientInfoServiceImpl.java b/postdischarge-manage/src/main/java/com/xinelu/manage/service/patientinfo/impl/PatientInfoServiceImpl.java index 611b0ace..f54eeee7 100644 --- a/postdischarge-manage/src/main/java/com/xinelu/manage/service/patientinfo/impl/PatientInfoServiceImpl.java +++ b/postdischarge-manage/src/main/java/com/xinelu/manage/service/patientinfo/impl/PatientInfoServiceImpl.java @@ -433,6 +433,13 @@ public class PatientInfoServiceImpl implements IPatientInfoService { if (Objects.nonNull(equalsDepartment.getId())) { patientInfoImport.setDepartmentId(equalsDepartment.getId()); patientInfoImport.setDepartmentName(equalsDepartment.getDepartmentName()); + //同一手机号每月可最多拔打xx次 + if (CollectionUtils.isNotEmpty(patientInfoList) && StringUtils.isNotBlank(aiobMaxCount)) { + List collect1 = patientInfoList.stream().filter(Objects::nonNull).filter(item -> patientInfoImport.getPatientPhone().equals(item.getPatientPhone()) && patientInfoImport.getDepartmentId().equals(item.getDepartmentId()) && item.getCountPhone() >= Long.parseLong(aiobMaxCount)).collect(Collectors.toList()); + if (CollectionUtils.isNotEmpty(collect1) || collect1.size() != 0) { + continue; + } + } patientInfoImportList.add(patientInfoImport); continue; //科室别名一致塞值 @@ -444,18 +451,18 @@ public class PatientInfoServiceImpl implements IPatientInfoService { if (StringUtils.isNotBlank(s)) { patientInfoImport.setDepartmentId(containsDepartment.getId()); patientInfoImport.setDepartmentName(containsDepartment.getDepartmentName()); + //同一手机号每月可最多拔打xx次 + if (CollectionUtils.isNotEmpty(patientInfoList) && StringUtils.isNotBlank(aiobMaxCount)) { + List collect1 = patientInfoList.stream().filter(Objects::nonNull).filter(item -> patientInfoImport.getPatientPhone().equals(item.getPatientPhone()) && patientInfoImport.getDepartmentId().equals(item.getDepartmentId()) && item.getCountPhone() >= Long.parseLong(aiobMaxCount)).collect(Collectors.toList()); + if (CollectionUtils.isNotEmpty(collect1) || collect1.size() != 0) { + continue; + } + } patientInfoImportList.add(patientInfoImport); continue; } } } - //同一手机号每月可最多拔打xx次 - if (CollectionUtils.isNotEmpty(patientInfoList) && StringUtils.isNotBlank(aiobMaxCount)) { - List collect1 = patientInfoList.stream().filter(Objects::nonNull).filter(item -> patientInfoImport.getPatientPhone().equals(item.getPatientPhone()) && patientInfoImport.getDepartmentId().equals(item.getDepartmentId()) && item.getCountPhone() >= Long.parseLong(aiobMaxCount)).collect(Collectors.toList()); - if (CollectionUtils.isNotEmpty(collect1) || collect1.size() != 0) { - continue; - } - } } //无科室名返回数据 DeptAliasVO deptAliasVO = new DeptAliasVO();