admin
2020-04-17 498db5b387d50dc76be41498200fa06d4e1def95
Merge remote-tracking branch 'origin/div' into div

Conflicts:
fanli/src/main/java/com/yeshi/fanli/service/impl/order/CommonOrderServiceImpl.java
18个文件已修改
1个文件已添加
228 ■■■■ 已修改文件
fanli/src/main/java/com/yeshi/fanli/aspect/ActiveUserAspect.java 22 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/client/v1/UserCouponController.java 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/UserOrderControllerV2.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/UserTopicTagEnum.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/body/UserActiveMQMsg.java 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/entity/bus/msg/MsgAccountDetail.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/entity/bus/msg/MsgInviteDetail.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/entity/bus/msg/MsgMoneyDetail.java 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/entity/bus/user/vip/UserLevelEnum.java 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java 61 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/CommonOrderServiceImpl.java 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/taobao/TaoBaoGoodsUpdateServiceImpl.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/invite/ThreeSaleSerivceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/vip/UserVIPInfoServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/vip/UserVIPPreInfoServiceImpl.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/inter/dynamic/GoodsEvaluateService.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/util/Constant.java 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/util/rocketmq/consumer/user/UserVIPMessageListener.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/aspect/ActiveUserAspect.java
@@ -1,6 +1,7 @@
package com.yeshi.fanli.aspect;
import java.lang.reflect.Method;
import java.util.Date;
import javax.annotation.Resource;
@@ -18,13 +19,20 @@
import org.springframework.stereotype.Component;
import org.yeshi.utils.NumberUtil;
import com.aliyun.openservices.ons.api.Message;
import com.aliyun.openservices.ons.api.Producer;
import com.yeshi.fanli.dto.mq.user.UserTopicTagEnum;
import com.yeshi.fanli.dto.mq.user.body.UserActiveMQMsg;
import com.yeshi.fanli.entity.bus.user.UserInfoExtra;
import com.yeshi.fanli.service.inter.user.UserInfoExtraService;
import com.yeshi.fanli.service.inter.user.UserInfoModifyRecordService;
import com.yeshi.fanli.service.inter.user.integral.IntegralGetService;
import com.yeshi.fanli.util.Constant;
import com.yeshi.fanli.util.StringUtil;
import com.yeshi.fanli.util.ThreadUtil;
import com.yeshi.fanli.util.annotation.UserActive;
import com.yeshi.fanli.util.rocketmq.MQMsgBodyFactory;
import com.yeshi.fanli.util.rocketmq.MQTopicName;
import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;
@@ -50,6 +58,10 @@
    @Resource
    private IntegralGetService integralGetService;
    @Resource(name = "producer")
    private Producer producer;
    private ExpressionParser parser = new SpelExpressionParser();
@@ -89,12 +101,12 @@
                            try {
                                if (!StringUtil.isNullOrEmpty(jedis.set(key, "1", new SetParams().nx().ex(300)))) {
                                    try {
                                        // TODO 用户活跃处理
                                        Long uid = Long.parseLong(uidStr);
                                        userInfoModifyRecordService.syncBeforeInfo(uid);
                                        UserInfoExtra extra = userInfoExtraService.getUserInfoExtra(uid);
                                        if (extra != null && !StringUtil.isNullOrEmpty(extra.getInviteCode()))
                                            integralGetService.addInviteActivate(uid);
                                        if (!Constant.IS_TEST) { // 活跃通知
                                            UserActiveMQMsg msg = new UserActiveMQMsg(uid, new Date());
                                            Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER, UserTopicTagEnum.userActve, msg);
                                            producer.send(message);
                                        }
                                    } catch (Exception e) {
                                    }
                                }
fanli/src/main/java/com/yeshi/fanli/controller/client/v1/UserCouponController.java
@@ -24,6 +24,7 @@
import com.yeshi.fanli.service.inter.user.DeviceLotteryRecordService;
import com.yeshi.fanli.service.inter.user.UserInfoExtraService;
import com.yeshi.fanli.service.inter.user.UserSystemCouponService;
import com.yeshi.fanli.service.inter.user.invite.UserInviteService;
import com.yeshi.fanli.service.inter.user.vip.UserVIPInfoService;
import com.yeshi.fanli.util.Constant;
import com.yeshi.fanli.vo.user.UserSystemCouponRecordVO;
@@ -70,6 +71,9 @@
    @Resource
    private UserVIPInfoService userVIPInfoService;
    @Resource
    private UserInviteService userInviteService;
    /**
     * 用户券列表查询
@@ -275,8 +279,11 @@
            JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult("用户未登录"));
            return;
        }
        if (userVIPInfoService.isVIP(uid)) {
            JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult("超级会员不可使用奖励券"));
        // 当前用户是否VIP
        boolean vip = userInviteService.verifyVIP(uid);
        if (vip) {
            JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult("会员不可使用奖励券"));
            return;
        }
        if (goodsType == null || goodsType > 3 || goodsType < 1) {
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/UserOrderControllerV2.java
@@ -749,14 +749,14 @@
            }
        } else {
            Date accountTime = hongBaoV2.getGetTime();
            if (accountTime != null) {
            // 到账时间 -红包金额限制
            if (accountTime != null && hongBao.compareTo(Constant.REWARD_COUPON_LIMIT_MONEY) <= 0) {
                boolean vip = userInviteService.verifyVIP(uid);
                Date endDay = DateUtil.plusDayDate(Constant.COUPON_REWARD_LIMIT_DAY, accountTime);
                long currentTime = java.lang.System.currentTimeMillis();
                if (endDay.getTime() > currentTime && !vip) {
                    UserSystemCouponRecord couponRecord = userSystemCouponRecordService.getRecordByOrderNo(orderNo, null);
                    if (couponRecord == null
                            || (couponRecord.getCouponType() == CouponTypeEnum.rebatePercentCoupon.name() && couponRecord.getState() != UserSystemCouponRecord.STATE_SUCCESS)) {
                    if (couponRecord == null) {
                        orderRebateVO.setCoupon(true);
                        orderRebateVO.setCouponType(1);
                        orderRebateVO.setCouponText("立即使用");
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/UserTopicTagEnum.java
@@ -5,6 +5,7 @@
import com.yeshi.fanli.dto.mq.user.body.InviteCodeActiveMQMsg;
import com.yeshi.fanli.dto.mq.user.body.ThreeSaleSeparateMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserAccountBindingMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserActiveMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserForbiddenMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInviteMQMsg;
@@ -12,11 +13,10 @@
import com.yeshi.fanli.dto.mq.user.body.UserRedPackGiftMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserRegisterMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserSystemCouponUseMQMsg;
import com.yeshi.fanli.util.annotation.UserActive;
public enum UserTopicTagEnum {
    userAccountBinding(UserAccountBindingMQMsg.class), // 用户账号绑定
    userActve(UserActive.class), // 用户活跃
    userActve(UserActiveMQMsg.class), // 用户活跃
    useSystemCoupon(UserSystemCouponUseMQMsg.class), // 系统券使用
    systemCouponDrawback(UserSystemCouponUseMQMsg.class), // 系统券退回
    inviteSuccess(UserInviteMQMsg.class), // 邀请成功
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/body/UserActiveMQMsg.java
New file
@@ -0,0 +1,40 @@
package com.yeshi.fanli.dto.mq.user.body;
import java.util.Date;
import com.yeshi.fanli.dto.mq.BaseMQMsgBody;
/**
 *  用户活跃
 *
 * @author Administrator
 *
 */
public class UserActiveMQMsg extends BaseMQMsgBody {
    private Long uid;
    private Date createTime;
    public UserActiveMQMsg(Long uid, Date createTime) {
        super();
        this.uid = uid;
        this.setCreateTime(createTime);
    }
    public Long getUid() {
        return uid;
    }
    public void setUid(Long uid) {
        this.uid = uid;
    }
    public Date getCreateTime() {
        return createTime;
    }
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}
fanli/src/main/java/com/yeshi/fanli/entity/bus/msg/MsgAccountDetail.java
@@ -25,7 +25,7 @@
        taoBaoAuthFail("账号绑定", "http://img.flqapp.com/resource/msg/icon_msg_account.png"),
        changeCode("账号修改", "http://img.flqapp.com/resource/msg/icon_msg_account.png"),
        vipApply("账户升级", "http://img.flqapp.com/resource/msg/icon_msg_account.png"),
        vipPgrade("等级成长","http://img.flqapp.com/resource/msg/icon_msg_account.png");
        vipPgrade("等级成长","http://img.flqapp.com/resource/msg/icon_msg_level.png");
        
        private final String desc;
        private final String icon;
fanli/src/main/java/com/yeshi/fanli/entity/bus/msg/MsgInviteDetail.java
@@ -20,8 +20,8 @@
        invite("邀请消息","http://img.flqapp.com/resource/msg/icon_msg_invite.png"),
        exchangeCode("恭喜你,邀请码兑换成功","http://img.flqapp.com/resource/msg/icon_msg_invite.png"),
        receiveGift("领取礼品","http://img.flqapp.com/resource/msg/icon_msg_invite.png"),
        fansUpgrade("粉丝升级","http://img.flqapp.com/resource/msg/icon_msg_invite.png"),
        fansDivorced("脱离提醒","http://img.flqapp.com/resource/msg/icon_msg_invite.png"),
        fansUpgrade("粉丝升级","http://img.flqapp.com/resource/msg/icon_msg_team_level.png"),
        fansDivorced("脱离提醒","http://img.flqapp.com/resource/msg/icon_msg_team_separate.png"),
        inviteSucceed("邀请提醒","http://img.flqapp.com/resource/msg/icon_msg_invite.png");
        
        private final String desc;
fanli/src/main/java/com/yeshi/fanli/entity/bus/msg/MsgMoneyDetail.java
@@ -19,12 +19,12 @@
@Table("yeshi_ec_msg_money")
public class MsgMoneyDetail {
    public enum MsgTypeMoneyTypeEnum {
        fanli("资金到账", "http://img.flqapp.com/resource/msg/icon_msg_fanli.png"),
        share("资金到账", "http://img.flqapp.com/resource/msg/icon_msg_share_money.png"),
        invite("资金到账", "http://img.flqapp.com/resource/msg/icon_msg_invite_money.png"),
        fanli("资金到账", "http://img.flqapp.com/resource/msg/icon_msg_money_recieve.png"),
        share("资金到账", "http://img.flqapp.com/resource/msg/icon_msg_money_recieve.png"),
        invite("资金到账", "http://img.flqapp.com/resource/msg/icon_msg_money_recieve.png"),
        extract("提现", "http://img.flqapp.com/resource/msg/icon_msg_extract.png"),
        fanliWeiQuan("资金退回","http://img.flqapp.com/resource/msg/icon_msg_fanli.png"),
        shareWeiQuan("资金退回", "http://img.flqapp.com/resource/msg/icon_msg_share_money.png"),
        fanliWeiQuan("资金退回","http://img.flqapp.com/resource/msg/icon_msg_money_drawback.png"),
        shareWeiQuan("资金退回", "http://img.flqapp.com/resource/msg/icon_msg_money_drawback.png"),
        extractAutoWX("自动提现", "http://img.flqapp.com/resource/money_detail/icon_system.png"),
        extractValid("提现验证", "http://img.flqapp.com/resource/msg/icon_msg_extract.png"),
        inviteWeiQuan("团队奖金扣除", "http://img.flqapp.com/resource/msg/icon_msg_invite_money.png"),
fanli/src/main/java/com/yeshi/fanli/entity/bus/user/vip/UserLevelEnum.java
@@ -1,11 +1,11 @@
package com.yeshi.fanli.entity.bus.user.vip;
public enum UserLevelEnum {
    daRen(0, 0, "快省达人", "actived", "http://www.baidu.com"),
    normalVIP(3, 30, "普通会员", "vipPre1", "http://www.baidu.com"),
    highVIP(7, 70, "高级会员", "vipPre2", "http://www.baidu.com"),
    superVIP(10, 100, "超级会员", "vip", "http://www.baidu.com"),
    tearcher(11, 101, "资深导师", "tearcher", "http://www.baidu.com");
    daRen(0, 0, "快省达人", "actived", "http://apph5.banliapp.com/AppInside/vipNew/supvip.html"),
    normalVIP(3, 30, "普通会员", "vipPre1", "http://apph5.banliapp.com/AppInside/vipNew/supvip.html"),
    highVIP(7, 70, "高级会员", "vipPre2", "http://apph5.banliapp.com/AppInside/vipNew/supvip.html"),
    superVIP(10, 100, "超级会员", "vip", "http://apph5.banliapp.com/AppInside/vipNew/supvip.html"),
    tearcher(11, 101, "资深导师", "tearcher", "http://apph5.banliapp.com/AppInside/vipNew/supvip.html");
    private int level;
    private int orderRank;
fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java
@@ -17,6 +17,7 @@
import javax.imageio.ImageIO;
import org.apache.commons.beanutils.PropertyUtils;
import org.springframework.cache.annotation.CacheEvict;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.core.task.TaskExecutor;
import org.springframework.stereotype.Service;
@@ -2298,6 +2299,66 @@
            goodsEvaluateDao.save(goodsEvaluate);
        }
    }
    @Override
    public void offlineTaoBaoGoods(Long goodsId) {
        try {
            if (goodsId == null) {
                return;
            }
            List<GoodsEvaluate> list = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_TAOBAO, goodsId);
            if (list == null || list.size() == 0) {
                return;
            }
            // 下架商品
            offlineGoods(list, Constant.SOURCE_TYPE_TAOBAO, goodsId);
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
    @CacheEvict(value = "dynamicCache", allEntries = true)
    private void offlineGoods(List<GoodsEvaluate> list, int goodsType, Long goodsId) {
        for (GoodsEvaluate goodsEvaluate : list) {
            // 商品下架
            GoodsDetailVO goodsDetailVO = goodsEvaluate.getGoods();
            goodsDetailVO.setState(1);
            List<ImgInfo> imgList = goodsEvaluate.getImgList();
            if (imgList == null || imgList.size() == 0) {
                goodsEvaluate.setUpdateTime(new Date());
                goodsEvaluateDao.save(goodsEvaluate);
                continue;
            }
            for (ImgInfo imgInfo : imgList) {
                SimpleGoods simpleGoods = imgInfo.getGoods();
                if (simpleGoods == null || simpleGoods.getGoodsId() != goodsId
                        || goodsType != simpleGoods.getGoodsType()) {
                    continue;
                }
                simpleGoods.setState(1);
                GoodsDetailVO goodsVO = imgInfo.getGoodsVO();
                goodsVO.setState(1);
                imgInfo.setGoods(simpleGoods);
                imgInfo.setGoodsVO(goodsVO);
            }
            goodsEvaluate.setImgList(imgList);
            goodsEvaluate.setUpdateTime(new Date());
            goodsEvaluateDao.save(goodsEvaluate);
        }
    }
    private void removeOverdue() {
        List<GoodsEvaluate> list = goodsEvaluateDao.queryOverdue();
fanli/src/main/java/com/yeshi/fanli/service/impl/order/CommonOrderServiceImpl.java
@@ -595,16 +595,16 @@
            if (HongBaoV2.TYPE_ZIGOU == hongBaoType) {
                // 奖励订单、免单 使用记录
                if (sourceType == null) {
                    couponFactory(order, hasRewardCoupon, hongBaoState, hongBaoType, null, uid, vip, acceptData);
                    couponFactory(order, hasRewardCoupon, hongBaoState, hongBaoType, null, uid, vip, acceptData, hongBao);
                } else if (sourceType == Constant.SOURCE_TYPE_TAOBAO) {
                    couponFactory(order, hasRewardCoupon, hongBaoState, hongBaoType, listRecordTB, uid, vip,
                            acceptData);
                            acceptData, hongBao);
                } else if (sourceType == Constant.SOURCE_TYPE_JD) {
                    couponFactory(order, hasRewardCoupon, hongBaoState, hongBaoType, listRecordJD, uid, vip,
                            acceptData);
                            acceptData, hongBao);
                } else if (sourceType == Constant.SOURCE_TYPE_PDD) {
                    couponFactory(order, hasRewardCoupon, hongBaoState, hongBaoType, listRecordPDD, uid, vip,
                            acceptData);
                            acceptData, hongBao);
                }
            }
@@ -627,7 +627,7 @@
     * @param signList
     */
    private void couponFactory(CommonOrderVO order, boolean hasRewardCoupon, Integer hongBaoState, Integer hongBaoType,
            List<UserSystemCouponRecord> list, Long uid, boolean vip, AcceptData acceptData) throws Exception {
            List<UserSystemCouponRecord> list, Long uid, boolean vip, AcceptData acceptData, BigDecimal hongBao) throws Exception {
        // 是否免单商品
        boolean freeOrder = false;
@@ -725,6 +725,11 @@
            order.setRewardDetail(rewardMap);
        }
        // 使用奖励券 金额额限制
        if (hongBao.compareTo(Constant.REWARD_COUPON_LIMIT_MONEY) > 0){
            return;
        }
        // 是否可使用奖励券
        if (!rewardSuccess && !freeOrder && HongBaoV2.TYPE_ZIGOU == hongBaoType
                && HongBaoV2.STATE_YILINGQU == hongBaoState && !vip && CommonOrder.STATE_WQ != order.getState()) {
@@ -2177,8 +2182,8 @@
                    if (UserSystemCouponRecord.STATE_FREE_ON == state) {
                        text = "免单中";
                    } else if (UserSystemCouponRecord.STATE_SUCCESS == state) {
                        text = "免单成功";
                    }
                        text = "已免单";
                    }
                }
                break;
            }
fanli/src/main/java/com/yeshi/fanli/service/impl/taobao/TaoBaoGoodsUpdateServiceImpl.java
@@ -122,6 +122,8 @@
        // 分享爆款数据删除
        shareHotGoodsService.deleteByGoodsId(auctionId);
        goodsEvaluateService.offlineTaoBaoGoods(auctionId);
    }
    @Transactional(rollbackFor = Exception.class)
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java
@@ -952,6 +952,7 @@
        }
        BigDecimal hongBao = orderVO.getHongBao();
        // 红包状态
        Integer hongBaoState = orderVO.getHongBaoState();
        // 红包类型
@@ -964,6 +965,11 @@
            if (order == null)
                throw new UserSystemCouponException(1, "该订单不存在");
            // 使用奖励券 金额额限制
            if (hongBao.compareTo(Constant.REWARD_COUPON_LIMIT_MONEY) > 0){
                throw new UserSystemCouponException(1, "该订单不能使用奖励券");
            }
            /* 奖金计算 以及相关红包信息处理 */
            // 转换成小数点
fanli/src/main/java/com/yeshi/fanli/service/impl/user/invite/ThreeSaleSerivceImpl.java
@@ -528,8 +528,8 @@
                    ThreeSale myBoss = threeSaleMapper.getMyBoss(bossId);
                    if (myBoss != null) {
                        UserInfo boss = userInfoService.selectByPKey(bossId);
                        userInviteMsgNotificationService.indirectInviteSuccess(bossId, boss.getNickName(),
                                invitee.getNickName(), invitee.getPortrait(), new Date());
                        userInviteMsgNotificationService.indirectInviteSuccess(myBoss.getBoss().getId(),
                                boss.getNickName(),    invitee.getNickName(), invitee.getPortrait(), new Date());
                    }
                } catch (Exception e) {
                    e.printStackTrace();
fanli/src/main/java/com/yeshi/fanli/service/impl/user/vip/UserVIPInfoServiceImpl.java
@@ -41,6 +41,7 @@
import com.yeshi.fanli.service.inter.user.vip.UserVipConfigService;
import com.yeshi.fanli.util.Constant;
import com.yeshi.fanli.util.StringUtil;
import com.yeshi.fanli.util.TimeUtil;
@Service
public class UserVIPInfoServiceImpl implements UserVIPInfoService {
@@ -251,8 +252,7 @@
        try {
            // 升级消息
            UserVIPPreInfo pre1 = userVIPPreInfoService.getVipByProcess(uid, UserVIPPreInfo.PROCESS_2);
            int days = DateUtil.daysBetween(pre1.getCreateTime(), new Date());
            userAccountMsgNotificationService.vipUpgradeSuccess(uid, days);
            userAccountMsgNotificationService.vipUpgradeSuccess(uid, TimeUtil.getDayDifferenceCount(pre1.getCreateTime(), new Date()));
            
            // 升级提醒上级
            userVIPPreInfoService.remindBoss(uid, "超级会员", getPassItem(uid), upgradeTime, false);
fanli/src/main/java/com/yeshi/fanli/service/impl/user/vip/UserVIPPreInfoServiceImpl.java
@@ -47,6 +47,7 @@
import com.yeshi.fanli.service.inter.user.vip.UserVipConfigService;
import com.yeshi.fanli.util.Constant;
import com.yeshi.fanli.util.StringUtil;
import com.yeshi.fanli.util.TimeUtil;
import com.yeshi.fanli.util.annotation.RequestSerializableByKeyService;
@Service
@@ -371,7 +372,7 @@
            if (userInfoRegister != null && userInfoRegister.getCreateTime() != null) {
                registerTime = userInfoRegister.getCreateTime();
            }
            int daysBetween = DateUtil.daysBetween(registerTime, new Date());
            int daysBetween = TimeUtil.getDayDifferenceCount(registerTime, new Date());
            userAccountMsgNotificationService.vipPreUpgrade(uid, "快省达人", "普通会员", daysBetween, limit1, limit2, type);
            
            // 升级弹框提示
@@ -457,7 +458,7 @@
                if (userInfoRegister != null && userInfoRegister.getCreateTime() != null) {
                    registerTime = userInfoRegister.getCreateTime();
                }
                daysBetween = DateUtil.daysBetween(registerTime, upgradeTime);
                daysBetween = TimeUtil.getDayDifferenceCount(registerTime, upgradeTime);
                
                // 金币奖励 (直接升级高级会员补齐一级奖励)
                goldcoinReward(uid);
fanli/src/main/java/com/yeshi/fanli/service/inter/dynamic/GoodsEvaluateService.java
@@ -166,5 +166,11 @@
     */
    public void addGoodsEvaluate(Long goodsId,List<ImgInfo> imgList, ActivityUser user, String title,String comment,Date startTime) throws GoodsEvaluateException;
    /**
     * 下架商品
     * @param goodsId
     */
    public void offlineTaoBaoGoods(Long goodsId);
}
fanli/src/main/java/com/yeshi/fanli/util/Constant.java
@@ -259,8 +259,11 @@
    // 新的规则生效时间
    public static final long NEW_ORDER_FANLI_RULE_TIME = TimeUtil.convertToTimeTemp("2020-04-14", "yyyy-MM-dd");
    // 新人抽奖-最大次数
    public static final int MAX_COUNT_LOTTERY_NEWBIES = 5;
    // 使用奖励券最大金额限制
    public static final BigDecimal REWARD_COUPON_LIMIT_MONEY = new BigDecimal("10");
    // 线程等待数量
    public static Set<Long> waitingThreadSet = new HashSet<>();
fanli/src/main/java/com/yeshi/fanli/util/rocketmq/consumer/user/UserVIPMessageListener.java
@@ -21,6 +21,7 @@
import com.yeshi.fanli.service.inter.user.invite.UserInviteValidNumService;
import com.yeshi.fanli.service.inter.user.vip.TeamUserLevelStatisticService;
import com.yeshi.fanli.service.inter.user.vip.UserVIPPreInfoService;
import com.yeshi.fanli.util.Constant;
import com.yeshi.fanli.util.rocketmq.MQTopicName;
/**
@@ -53,6 +54,10 @@
        if (tag == null)
            tag = "";
        if (java.lang.System.currentTimeMillis() <= Constant.NEW_ORDER_FANLI_RULE_TIME) {
            return Action.CommitMessage;
        }
        // 邀请相关
        if (MQTopicName.TOPIC_USER.name().equalsIgnoreCase(message.getTopic())) {
            if (tag.equalsIgnoreCase(UserTopicTagEnum.userLevelChanged.name())) {// 用户等级发生变化