📄 receivedetailservice.java
字号:
/* * Created on 2008-09-24 16:40:11 * * By Yehailong * Copyright juneng.com.cn, 2005-2006, All rights reserved. */package cn.com.juneng.receivedetail.service;import java.util.List;import java.io.Serializable;import cn.com.juneng.system.common.COMMON;import cn.com.juneng.receivedetail.vo.ReceivedetailVOImpl;import cn.com.juneng.receivedetail.dao.ReceivedetailDAO;/** * service类,由Spring容器注入DAO实现,并管理事务性 * @author xiean */public class ReceivedetailService { private ReceivedetailDAO receivedetailDAO; /** * spring注入dao实现 * @param receivedetailDAO */ public void setReceivedetailDAO(ReceivedetailDAO receivedetailDAO) { this.receivedetailDAO = receivedetailDAO; } public ReceivedetailDAO getReceivedetailDAO() { return this.receivedetailDAO; } public void remove(Serializable[] key)throws Exception{ if(key!=null){ for (int i=0;i<key.length ;i++ ){ receivedetailDAO.remove(key[i]); } } } public ReceivedetailVOImpl findByPrimaryKey(String key)throws Exception{ return receivedetailDAO.findByPrimaryKey(key); } public void create(Object obj)throws Exception{ receivedetailDAO.create(obj); } public void update(Object obj)throws Exception{ receivedetailDAO.update(obj); } public List getList(String queryHql,String orderHql,int start, int maxResults) throws Exception { String hql = "from ReceivedetailVOImpl "; if(!COMMON.isEmpty(queryHql)){ hql += "where "+queryHql; } if(COMMON.isEmpty(orderHql)){ orderHql = " order by rid desc"; } hql += " "+orderHql; return receivedetailDAO.find(hql,start,maxResults); } public int getRowCount(String queryHql){ String hql = "from ReceivedetailVOImpl "; if(!COMMON.isEmpty(queryHql)){ hql += "where "+queryHql; } return receivedetailDAO.getRowCount(hql,null); }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -