From 70e487806e45676b00d15142a5fae214169e7ac6 Mon Sep 17 00:00:00 2001 From: qiuyt Date: Sat, 11 Jan 2025 15:25:20 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=84=E7=90=86=E6=9E=81=E7=AB=AF=E6=83=85?= =?UTF-8?q?=E5=86=B5=E9=98=BF=E6=8B=89=E4=BC=AF=E6=95=B0=E5=AD=97=E7=9A=84?= =?UTF-8?q?=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../collect/ThirdAliDrugController.java | 21 ++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/glxp/udidl/admin/controller/collect/ThirdAliDrugController.java b/src/main/java/com/glxp/udidl/admin/controller/collect/ThirdAliDrugController.java index 767982c..d1d234a 100644 --- a/src/main/java/com/glxp/udidl/admin/controller/collect/ThirdAliDrugController.java +++ b/src/main/java/com/glxp/udidl/admin/controller/collect/ThirdAliDrugController.java @@ -59,6 +59,8 @@ public class ThirdAliDrugController { return ResultVOUtils.success("查询参数不能为空"); } List list = thirdAliDrugService.filterList(thirdAliDrug); + List nameCodeIn = thirdAliDrug.getNameCodeIn(); + if (CollUtil.isEmpty(list)){ // 剔除当前选入的产品编码要给他删了再重新查一次判断 如果还是查不到就去查阿里 thirdAliDrug.setNameCodeIn(null); @@ -93,9 +95,26 @@ public class ThirdAliDrugController { log.error("异步更新阿里药品数据错误==="+e.getMessage()); } }); + // 判断中文括号和英文括号的就今昔新的结果进行剔除 + if(thirdAliDrug.getCpmctymc().contains("(") || thirdAliDrug.getCpmctymc().contains("(")){ + List listResult = new ArrayList<>(); + + if(CollUtil.isNotEmpty(list)){ + for (ThirdAliDrug aliDrug : list) { + if(!nameCodeIn.contains(aliDrug.getNameCode())){ + listResult.add(aliDrug); + + } + } + list = listResult; + } + } + + } } + PageInfo pageInfo = new PageInfo<>(list); PageSimpleResponse pageSimpleResponse = new PageSimpleResponse<>(); pageSimpleResponse.setTotal(pageInfo.getTotal()); @@ -140,7 +159,7 @@ public class ThirdAliDrugController { thirdAliDrugList = thirdAliDrugService.list( new QueryWrapper().eq(StringUtils.isNotBlank(thirdAliDrugServiceOne.getBzgg()), "bzgg", thirdAliDrugServiceOne.getBzgg()) .eq(StringUtils.isNotBlank(thirdAliDrugServiceOne.getPackRatio()), "packRatio", thirdAliDrugServiceOne.getPackRatio()) - .like(StringUtils.isNotBlank(thirdAliDrugRequest.getCpmctymc()), "cpmctymc", thirdAliDrugRequest.getCpmctymc()) + .likeLeft(StringUtils.isNotBlank(thirdAliDrugServiceOne.getCpmctymc()), "cpmctymc", thirdAliDrugServiceOne.getCpmctymc()) .like(StringUtils.isNotBlank(thirdAliDrugRequest.getManufacturer()), "manufacturer", thirdAliDrugRequest.getManufacturer()) .like(StringUtils.isNotBlank(thirdAliDrugRequest.getApprovalNum()), "approvalNum", thirdAliDrugRequest.getApprovalNum()) .like(StringUtils.isNotBlank(thirdAliDrugRequest.getFormSpec()), "formSpec", thirdAliDrugRequest.getFormSpec())