public BackMoneyRequest findById(Long id) { // TODO Auto-generated method stub logger.debug("findById BackMoneyRequest"); BackMoneyRequest backMoneyRequest = (BackMoneyRequest) backMoneyRequestDao.getSession().get(BackMoneyRequest.class, id); return backMoneyRequest; }
/** 提现金额统计 */ public BigDecimal getSumMoneyByApplyTime(Calendar f_stime, Calendar f_etime) { // TODO Auto-generated method stub Criteria criteria = backMoneyRequestDao.createCriteria(); criteria.setProjection(Projections.projectionList().add(Projections.sum("money"))); if (null != f_stime) { criteria.add(Restrictions.ge("applyTime", f_stime)); } if (null != f_etime) { criteria.add(Restrictions.le("applyTime", f_etime)); } List list = criteria.add(Restrictions.eq("status", BackMoneyStatus.已成功)).list(); BigDecimal money = new BigDecimal(0.00); Object obj = list.get(0); if (obj != null) { money = (BigDecimal) obj; } return money; }
public BackMoneyRequest update(BackMoneyRequest entity) { // TODO Auto-generated method stub logger.debug("update BackMoneyRequest"); backMoneyRequestDao.getSession().update(entity); return entity; }
public BackMoneyRequest save(BackMoneyRequest entity) { // TODO Auto-generated method stub logger.debug("save BackMoneyRequest"); backMoneyRequestDao.save(entity); return entity; }
public BackMoneyRequest load(Long id) { // TODO Auto-generated method stub logger.debug("load BackMoneyRequest"); BackMoneyRequest backMoneyRequest = backMoneyRequestDao.get(id); return backMoneyRequest; }
public void delete(BackMoneyRequest entity) { // TODO Auto-generated method stub logger.debug("delete BackMoneyRequest"); backMoneyRequestDao.delete(entity); }
public TermTypeConfig update(TermTypeConfig entity) { termConfigDao.save(entity); return entity; }
@Transactional(propagation = Propagation.NOT_SUPPORTED, readOnly = true) public TermTypeConfig load(Long id) { return termConfigDao.get(id); }
@Transactional(propagation = Propagation.NOT_SUPPORTED, readOnly = true) public TermTypeConfig findById(Long id) { return (TermTypeConfig) termConfigDao.getSession().get(TermTypeConfig.class, id); }
public void delete(TermTypeConfig entity) { logger.debug("delete TermTypeConfig "); termConfigDao.delete(entity); }
/** 根据彩种查找配置 */ @Transactional(propagation = Propagation.NOT_SUPPORTED, readOnly = true) public TermTypeConfig getConfigByType(LotteryType type) { logger.debug("find TermTypeConfig by type"); return termConfigDao.findUniqueByProperty("type", type); }