| 
					
				 | 
			
			
				@ -21,6 +21,7 @@ import org.springframework.data.redis.core.StringRedisTemplate; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.stereotype.Service; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.transaction.annotation.Transactional; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.util.Assert; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.util.CollectionUtils; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.web.multipart.MultipartFile; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import javax.validation.constraints.NotNull; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -138,14 +139,21 @@ public class PatientService extends BasePatientService<BasePatientDO, BasePatien 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        //将预注册信息存到redis中 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        redisTemplate.opsForValue().set(BespeakRegist+mobile , mobile, time, TimeUnit.MINUTES); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        BasePatientDO patient = new BasePatientDO(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        patient.setMobile(mobile); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        patient.setLocked(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        patient.setEnabled(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        patient.setDel("0"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        patient.setLoginFailureCount(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        patient.setPatientStatus("1"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        patient = this.save(patient); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        //判断是否存在del=0的数据 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        list = basePatientDao.findByMobileAndDel(mobile,"0"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        BasePatientDO patient = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        if(CollectionUtils.isEmpty(list)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient = new BasePatientDO(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient.setMobile(mobile); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient.setLocked(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient.setEnabled(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient.setDel("0"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient.setLoginFailureCount(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient.setPatientStatus("1"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient = this.save(patient); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        }else{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            patient = list.get(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        map.put("code",1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        map.put("message","预注册成功"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        map.put("patient",patient); 
			 |