| 
					
				 | 
			
			
				@ -374,26 +374,24 @@ public class ContactsService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        if (StringUtils.isNotBlank(response)) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            String[] DelNums = del_num.split("_"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            for (String tmp:DelNums){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                if (!delSuccess.contains(tmp)){//本次已删除过 不再作删除操作 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    String deviceCode = simTmp.get("device_sn").toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    JSONObject aqgDeviceInfo = patientDeviceService.getAqgDeviceInfo(deviceCode); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    JSONArray aqgDeviceSosNum = aqgDeviceInfo.getJSONArray("sos_numbers"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    Integer numIndex=0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    for (int i=0;i<aqgDeviceSosNum.size();i++){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                        JSONObject aqgTmp = aqgDeviceSosNum.getJSONObject(i); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                        String aqgNum = aqgTmp.getString("num"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                        if (aqgNum.equals(tmp)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                            numIndex = aqgTmp.getInteger("seqid"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                            break; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    if (numIndex!=0){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                      JSONObject response2 =  patientDeviceService.updAqgDeviceSosInfo(deviceCode,numIndex+"",null,null,null,"1"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                      if (response2.getBoolean("success")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                          delSuccess += "_"+tmp; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                      } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                String deviceCode = simTmp.get("device_sn").toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                JSONObject aqgDeviceInfo = patientDeviceService.getAqgDeviceInfo(deviceCode); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                JSONArray aqgDeviceSosNum = aqgDeviceInfo.getJSONArray("sos_numbers"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                Integer numIndex=0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                for (int i=0;i<aqgDeviceSosNum.size();i++){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    JSONObject aqgTmp = aqgDeviceSosNum.getJSONObject(i); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    String aqgNum = aqgTmp.getString("num"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    if (aqgNum.equals(tmp)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                        numIndex = aqgTmp.getInteger("seqid"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                        break; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                if (numIndex!=0){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                  JSONObject response2 =  patientDeviceService.updAqgDeviceSosInfo(deviceCode,numIndex+"",null,null,null,"1"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                  if (response2.getBoolean("success")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                      delSuccess += "_"+tmp; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                  } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -404,7 +402,7 @@ public class ContactsService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        //保存修改记录 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        List<PatientSosContactsDO> modify = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        for (String num:numTmp){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        for(String num:numTmp){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            if (StringUtils.isNotBlank(num)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                PatientSosContactsDO patientSosContactsDO = sosContactsDao.findByPatientAndSosPhone(patient,num); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                patientSosContactsDO.setUpdateTime(new Date()); 
			 |