| 
					
				 | 
			
			
				@ -5,6 +5,9 @@ import com.yihu.jw.entity.care.course.DoctorPatientTmpDO; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.beans.factory.annotation.Autowired; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.stereotype.Component; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import java.util.ArrayList; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import java.util.List; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				/** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 * 教师与新生儿 入学关系更新工具 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 * Created by Bing on 2021/6/11. 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -52,6 +55,22 @@ public class EntranceUtil { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     * 更新状态 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     * @param relationCode 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    public void updateStatus2(Integer status,String[] relationCode) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        List<DoctorPatientTmpDO> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        for (String id : relationCode) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            DoctorPatientTmpDO tmpDO = doctorPatientTmpDao.findByRelationCode(id); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            if (tmpDO != null) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                tmpDO.setStatus(status); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                list.add(tmpDO); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        doctorPatientTmpDao.save(list); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     * 删除记录 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     * @param relationCode 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -65,4 +84,19 @@ public class EntranceUtil { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        doctorPatientTmpDao.save(tmpDO); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     * 删除记录 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     * @param relationCode 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    public void deleteRecord2(String[] relationCode){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        List<DoctorPatientTmpDO> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        for (String id : relationCode) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            DoctorPatientTmpDO tmpDO = doctorPatientTmpDao.findByRelationCode(id); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            if (tmpDO!=null){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                tmpDO.setDel(0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        doctorPatientTmpDao.save(list); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				} 
			 |