⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 humanfilebiz.java

📁 人力资源管理系统
💻 JAVA
字号:
package com.accphr.biz.impl;

import java.io.Serializable;
import java.util.List;

import com.accphr.biz.IHumanFileBiz;
import com.accphr.dao.ICommonDao;
import com.accphr.entity.HumanFile;
import com.accphr.page.PageResult;


/**
 * 人力资源档案管理
 * 映射表`human_file`
 * @author zhuohai
 *
 */
public class HumanFileBiz implements IHumanFileBiz {

	private ICommonDao commonDao;

	public void setCommonDao(ICommonDao commonDao) {
		this.commonDao = commonDao;
	}
	
	//添加信息
	/* (non-Javadoc)
	 * @see com.accphr.biz.impl.IHumanFileBiz#add(com.accphr.entity.HumanFile)
	 */
	public void add(HumanFile humanFile){
		this.commonDao.add(humanFile);
	}
	
	//更新信息
	/* (non-Javadoc)
	 * @see com.accphr.biz.impl.IHumanFileBiz#update(com.accphr.entity.HumanFile)
	 */
	public void update(HumanFile humanFile){
		this.commonDao.update(humanFile);
	}
	
	//删除信息
	/* (non-Javadoc)
	 * @see com.accphr.biz.impl.IHumanFileBiz#del(java.io.Serializable)
	 */
	public void del(Serializable serializable){
		this.commonDao.del(HumanFile.class, serializable);
	}
	
	//分页查询
	/* (non-Javadoc)
	 * @see com.accphr.biz.impl.IHumanFileBiz#setPageResult(com.accphr.entity.HumanFile, com.accphr.page.PageResult)
	 */
	public void setPageResult(HumanFile humanFile,PageResult pageResult){
		String hql="from HumanFile where 1=1";
		if(humanFile!=null){
			if(humanFile.getFirstKindId()!=null&&humanFile.getFirstKindId()!=-1){
				hql+=" and firstKindId = "+humanFile.getFirstKindId()+"";
			}
			if(humanFile.getSecondKindId()!=null&&humanFile.getSecondKindId()!=-1){
				hql+=" and secondKindId = "+humanFile.getSecondKindId()+"";
			}
			if(humanFile.getThirdKindId()!=null&&humanFile.getThirdKindId()!=-1){
				hql+=" and thirdKindId = "+humanFile.getThirdKindId()+"";
			}
			if(humanFile.getHumanMajorKindId()!=null&&humanFile.getHumanMajorKindId()!=-1){
				hql+=" and humanMajorKindId = "+humanFile.getHumanMajorId()+"";
			}
			if(humanFile.getHumanMajorId()!=null&&humanFile.getHumanMajorId()!=-1){
				hql+=" and humanMajorId = "+humanFile.getHumanMajorId()+"";
			}
			
			if(humanFile.getRegistTime()!=null){
				hql+=" and registTime like "+humanFile.getRegistTime()+"";
			}
			if(humanFile.getCheckStatus()!=null){
				hql+=" and checkStatus="+humanFile.getCheckStatus();
			}
			
			if(humanFile.getHumanFileStatus()!=null){
				hql+=" and humanFileStatus="+humanFile.getHumanFileStatus();
			}
			
		}
		pageResult.setHql(hql);
		this.commonDao.pageList(pageResult);
	}
	
	//根据ID查询信息
	/* (non-Javadoc)
	 * @see com.accphr.biz.impl.IHumanFileBiz#findById(java.io.Serializable)
	 */
	public HumanFile findById(Serializable serializable){
		String hql=" from HumanFile where hufId=?";
		List list=this.commonDao.findByHql(hql, new Object[]{serializable});
		if(list.size()>0){
			return (HumanFile)list.get(0);
		}
		else{
			return null;
		}
	}
	
	//状态修改
	/* (non-Javadoc)
	 * @see com.accphr.biz.impl.IHumanFileBiz#changeStatus(java.io.Serializable)
	 */
	public void changeStatus(Serializable serializable){
		
		
	}
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -