yujian
2019-08-27 d8359ddb48dab5cc797a9d552e11fde571f4920c
fanli/src/main/java/com/yeshi/fanli/service/impl/user/TokenRecordServiceImpl.java
@@ -8,6 +8,7 @@
import javax.annotation.Resource;
import org.springframework.context.annotation.Lazy;
import org.springframework.core.task.TaskExecutor;
import org.springframework.stereotype.Service;
@@ -80,6 +81,7 @@
   @Resource
   private UserOtherMsgNotificationService userOtherMsgNotificationService;
   
   @Lazy
   @Resource
   private IntegralGetService  integralGetService;
   
@@ -117,8 +119,8 @@
         throw new TokenRecordException(1, "口令不存在");
      Long uidToken = rokenRecord.getUid();
//      if (uid != null && uidToken != null && uid.longValue() == uidToken.longValue())
//         throw new TokenRecordException(1, "不能自己赠送给自己");
      if (uid != null && uidToken != null && uid.longValue() == uidToken.longValue())
         throw new TokenRecordException(1, "不能自己赠送给自己");
      
      Date now = new Date();
      Date endTimeToken = rokenRecord.getEndTime();
@@ -289,9 +291,9 @@
      if (rokenRecord == null)
         throw new TokenRecordException(1, "口令已失效");
      
//      Long uidToken = rokenRecord.getUid();
//      if (uidToken != null && uid.longValue() == uidToken.longValue())
//         throw new TokenRecordException(1, "不能自己赠送给自己");
      Long uidToken = rokenRecord.getUid();
      if (uidToken != null && uid.longValue() == uidToken.longValue())
         throw new TokenRecordException(1, "不能自己赠送给自己");
      
      Date now = new Date();
      Date endTimeToken = rokenRecord.getEndTime();