📄 engageresumebiz.java
字号:
package com.accphr.biz.impl;
import java.io.Serializable;
import java.util.List;
import com.accphr.biz.IEngageResumeBiz;
import com.accphr.dao.ICommonDao;
import com.accphr.entity.EngageResume;
import com.accphr.page.PageResult;
/*
* 简历管理
*/
public class EngageResumeBiz implements IEngageResumeBiz {
private ICommonDao commonDao=null;
public void setCommonDao(ICommonDao commonDao) {
this.commonDao = commonDao;
}
//保存
/* (non-Javadoc)
* @see com.accphr.biz.impl.IEngageResumeBiz#add(com.accphr.entity.EngageResume)
*/
public void add(EngageResume engageResume){
this.commonDao.add(engageResume);
}
//删除
/* (non-Javadoc)
* @see com.accphr.biz.impl.IEngageResumeBiz#del(java.io.Serializable)
*/
public void del(Serializable erid){
this.commonDao.del(EngageResume.class, erid);
}
//更新
/* (non-Javadoc)
* @see com.accphr.biz.impl.IEngageResumeBiz#update(com.accphr.entity.EngageResume)
*/
public void update(EngageResume engageResume){
this.commonDao.update(engageResume);
}
//分页查询
/* (non-Javadoc)
* @see com.accphr.biz.impl.IEngageResumeBiz#setPageResult(com.accphr.entity.EngageResume, com.accphr.page.PageResult)
*/
public void setPageResult(EngageResume engageResume,PageResult pageResult){
String hql=" from EngageResume where 1=1";
if(engageResume!=null){
if(engageResume.getHumanMajorKindId()!=null&&engageResume.getHumanMajorKindId().length()>0){
hql+=" and humanMajorKindId = "+engageResume.getHumanMajorKindId();
}
if(engageResume.getHumanMajorId()!=null&&engageResume.getHumanMajorId().length()>0){
hql+=" and humanMajorId ="+engageResume.getHumanMajorId();
}
if(engageResume.getRemark()!=null&&engageResume.getAttachmentName()!=null&&engageResume.getRemark().length()>0&&engageResume.getAttachmentName().length()>0){
hql+=" and (registTime BETWEEN '"+engageResume.getRemark()+"' and '"+engageResume.getAttachmentName()+"')";
}else if(engageResume.getRemark()!=null&&engageResume.getAttachmentName()==null&&engageResume.getRemark().length()>0){
hql+=" and registTime > '"+engageResume.getRemark()+"'";
}else if(engageResume.getRemark()==null&&engageResume.getAttachmentName()!=null&&engageResume.getAttachmentName().length()>0){
hql+=" and registTime < '"+engageResume.getAttachmentName()+"'";
}
if(engageResume.getHumanName()!=null){
hql+=" and (humanName like '%"+engageResume.getHumanName()+"%'";
}
if(engageResume.getHumanHistoryRecords()!=null){
hql+=" or humanHistoryRecords like '%"+engageResume.getHumanHistoryRecords()+"%')";
}
if(engageResume.getCheckStatus()!=null&&engageResume.getCheckStatus().toString().length()>0){
hql+=" and checkStatus ="+engageResume.getCheckStatus();
}
}
//System.out.println(hql);
pageResult.setHql(hql);
this.commonDao.pageList(pageResult);
}
//根据ID查询
/* (non-Javadoc)
* @see com.accphr.biz.impl.IEngageResumeBiz#findById(java.io.Serializable)
*/
public EngageResume findById(Serializable id) {
return (EngageResume)this.commonDao.findById(EngageResume.class, id);
}
//根据ID查询
/* (non-Javadoc)
* @see com.accphr.biz.impl.IEngageResumeBiz#findById(java.io.Serializable)
*/
public List findByPro(EngageResume engageResume) {
String hql=" from EngageResume where 1=1";
if(engageResume!=null){
if(engageResume.getHumanMajorKindId()!=null&&engageResume.getHumanMajorKindId().length()>0){
hql+=" and humanMajorKindId = "+engageResume.getHumanMajorKindId();
}
if(engageResume.getHumanMajorId()!=null&&engageResume.getHumanMajorId().length()>0){
hql+=" and humanMajorId ="+engageResume.getHumanMajorId();
}
if(engageResume.getHumanName()!=null){
hql+=" and humanName = '"+engageResume.getHumanName()+"'";
}
if(engageResume.getHumanIdcard()!=null){
hql+=" and humanIdcard ='"+engageResume.getHumanIdcard()+"'";
}
}
return this.commonDao.findByHql(hql);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -