From 4e13212e51fd48cb66d5d2d6f9bcd3c47c4be6f2 Mon Sep 17 00:00:00 2001 From: changpengfei Date: Wed, 8 Sep 2021 19:53:42 +0800 Subject: [PATCH] =?UTF-8?q?=E7=97=85=E4=BE=8B=E5=AD=97=E6=AE=B5=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/lyms/talkonlineweb/controller/PatientController.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/talkonlineweb/src/main/java/com/lyms/talkonlineweb/controller/PatientController.java b/talkonlineweb/src/main/java/com/lyms/talkonlineweb/controller/PatientController.java index 0f5c84c..993ec3d 100644 --- a/talkonlineweb/src/main/java/com/lyms/talkonlineweb/controller/PatientController.java +++ b/talkonlineweb/src/main/java/com/lyms/talkonlineweb/controller/PatientController.java @@ -106,6 +106,7 @@ public class PatientController { log.info(patient); log.info(pcase); + Map param=new HashMap(); for (int i = 0; i < iArr.length; i++) { LymsIllness ness=new LymsIllness(); @@ -113,6 +114,13 @@ public class PatientController { ness.setPcid(pcase.getPcid()); ness.setIid(Integer.parseInt(iArr[i])); ness.setCreatedtime(new Date()); + param.clear(); + param.put("pcid",pcase.getPcid()); + param.put("iid",iArr[i]); + List iLst=lymsIllnessService.listByMap(param); + if(iLst.size()>0){ + ness.setId(iLst.get(0).getId()); + } f=lymsIllnessService.saveOrUpdate(ness); log.info(ness); } -- 1.8.3.1