Beispiel #1
0
 public int addReward(T01RewardExp t01RewardExp) throws DaoException {
   String sql = "insert into t01_rewarded_exp values (null,?,?,?,?)";
   if (logger.isDebugEnabled()) {
     logger.debug("**sql:" + sql);
     logger.debug("**rid:" + t01RewardExp);
   }
   IDao dao = DaoFactory.createDaoInstance();
   return dao.update(
       "ijsp",
       sql,
       new Object[] {
         t01RewardExp.getRSid(),
         t01RewardExp.getRewardName(),
         t01RewardExp.getRewardTime(),
         t01RewardExp.getOrganization()
       });
 }
Beispiel #2
0
 public int updateReward(T01RewardExp t01RewardExp) throws DaoException {
   String sql =
       "update t01_rewarded_exp set rewardName=?, rewardTime=?,organization=? where rid = ?";
   if (logger.isDebugEnabled()) {
     logger.debug("**sql:" + sql);
     logger.debug("**rid:" + t01RewardExp);
   }
   IDao dao = DaoFactory.createDaoInstance();
   return dao.update(
       "ijsp",
       sql,
       new Object[] {
         t01RewardExp.getRewardName(),
         t01RewardExp.getRewardTime(),
         t01RewardExp.getOrganization(),
         t01RewardExp.getRid()
       });
 }