From 54402107ca335c2896fc9c61864f6054ad5bfabb Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期一, 16 十二月 2019 16:07:15 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/div' into div --- fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java index 6adf1af..c9f73e0 100644 --- a/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java +++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java @@ -2075,12 +2075,13 @@ } Date nowDate = new Date(); + Date endTime = DateUtil.plusDayDate(Constant.GIVE_DAYS, nowDate); // 鎻掑叆璧犻�佽褰� UserSystemCouponGiveRecord giveRecord = new UserSystemCouponGiveRecord(); giveRecord.setCouponId(id); giveRecord.setGiveUid(uid); giveRecord.setGiveTime(nowDate); - giveRecord.setEndTime(DateUtil.plusDayDate(Constant.GIVE_DAYS, nowDate)); + giveRecord.setEndTime(endTime); userSystemCouponGiveRecordService.insertSelective(giveRecord); // 鍒涘缓璁板綍 @@ -2089,7 +2090,7 @@ tokenRecord.setIdentify(giveRecord.getId() + ""); tokenRecord.setType(tokenTypeEnum); tokenRecord.setStartTime(nowDate); - tokenRecord.setEndTime(DateUtil.plusDayDate(Constant.TOKEN_DAYS, nowDate)); + tokenRecord.setEndTime(endTime); tokenRecord.setState(0); tokenRecordService.insertSelective(tokenRecord); @@ -2125,6 +2126,8 @@ msg.setUserSystemCouponId(id); msg.setCouponType(type.name()); Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER, UserTopicTagEnum.systemCouponDrawback, msg); + // 寤惰繜涓�鍒嗛挓 + message.setStartDeliverTime(endTime.getTime() + 1000 * 60); try { producer.send(message); } catch (Exception e) { @@ -2317,7 +2320,7 @@ } @Override - @RequestSerializableByKeyService(key = "#id") + @RequestSerializableByKeyService(key = "#couponId") @Transactional(rollbackFor = Exception.class) public void sendBackByGiveId(Long couponId) { if (couponId == null) -- Gitblit v1.8.0