yujian
2019-08-16 8e631ceb2c08e6cd00e68b1aa9ad1fec7cea6a72
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponGiveRecordServiceImpl.java
@@ -1,7 +1,5 @@
package com.yeshi.fanli.service.impl.user;
import java.util.Date;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
@@ -23,14 +21,12 @@
   }
   
   @Override
   public void updateRecord(Long receiveUid, Long giveUid, Long couponId) {
      UserSystemCouponGiveRecord record = userSystemCouponGiveRecordMapper.getRecordByUidAndCouponId(giveUid, couponId);
      if (record != null) {
         UserSystemCouponGiveRecord giveRecord = new UserSystemCouponGiveRecord();
         giveRecord.setId(record.getId());
         giveRecord.setReceiveUid(receiveUid);
         giveRecord.setReceiveTime(new Date());
         userSystemCouponGiveRecordMapper.updateByPrimaryKeySelective(giveRecord);
      }
   public UserSystemCouponGiveRecord getRecordByUidAndCouponId(Long giveUid, Long couponId) {
      return userSystemCouponGiveRecordMapper.getRecordByUidAndCouponId(giveUid, couponId);
   }
   @Override
   public void updateByPrimaryKeySelective(UserSystemCouponGiveRecord giveRecord) {
      userSystemCouponGiveRecordMapper.updateByPrimaryKeySelective(giveRecord);
   }
}