yujian
2019-12-19 bb07147aaa96d1ef4c99e358dbbe7dad160dc62a
Merge branch 'div' of ssh://193.112.35.168:29418/fanli-server into div
1个文件已删除
89个文件已修改
2个文件已添加
1327 ■■■■■ 已修改文件
fanli/src/main/java/com/yeshi/fanli/controller/admin/UserInfoAdminController.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/client/v1/RecommendController.java 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/client/v1/ShareController.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/GoodsControllerV2.java 27 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/SearchControllerV2.java 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/ShareControllerV2.java 45 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dao/BaseDao.java 211 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dao/mybatis/UserInfoMapper.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dao/mybatis/order/UserOrderWeiQuanRecordMapper.java 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/UserTopicTagEnum.java 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/body/InviteCodeActiveMQMsg.java 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/body/UserInfoUpdateMQMsg.java 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/entity/elme/ElmeOrder.java 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/job/order/jd/UpdateJDOrderJob.java 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/mapping/UserInfoMapper.xml 39 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/mapping/homemodule/SpecialMapper.xml 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/mapping/order/UserOrderWeiQuanRecordMapper.xml 136 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/activity/ActivityServiceImpl.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/brand/BrandClassShopServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/config/SystemClientParamsServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/elme/ElmeHongBaoOrderMapServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/elme/ElmeOrderProcessServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/CollectionGoodsV2ServiceImpl.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/GoodsClassServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/GoodsSubClassServiceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/RecommendUserGoodsServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/ShareGoodsTextTemplateServiceImpl.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/help/HelpCenterServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/FloatADServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SpecialCardServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SpecialPlaceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SpecialServiceImpl.java 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SwiperBannerServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SwiperPictureServiceImpl.java 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/jd/JDGoodsServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/BoutiqueAutoRuleServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/LabelClassServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/LabelGoodsServiceImpl.java 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/LabelServiceImpl.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/QualityFactoryServiceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/money/InviteOrderSubsidyDebtServiceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/money/UserMoneyDebtServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/money/extract/BindingAccountServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/money/extract/ExtractServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/money/tb/TaoBaoWeiQuanDrawBackServiceImpl.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/msg/UserSystemMsgServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/CommonOrderServiceImpl.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/HongBaoV2ServiceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/InviteOrderSubsidyServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderMoneySettleServiceImpl.java 16 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderProcessServiceImpl.java 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderRepairServiceImpl.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/UserOrderWeiQuanRecordServiceImpl.java 110 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/jd/JDOrderServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/order/tb/TaoBaoWeiQuanOrderServiceImpl.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/pdd/PDDGoodsServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/push/IOSPushServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/push/PushCouponServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/push/PushGoodsServiceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/push/PushInfoServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/redpack/RedPackWinInviteServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopGoodsSetPayServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopGoodsSetServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopOrderPayServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopOrderServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/taobao/TaoBaoBuyRelationMapServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/taobao/TaoBaoGoodsUpdateServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/tlj/UserTaoLiJinNewbiesServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/tlj/UserTaoLiJinRecordServiceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/SpreadUserImgServiceImpl.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserAccountServiceImpl.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserGoodsStorageServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserInfoExtraServiceImpl.java 88 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserInfoModifyRecordServiceImpl.java 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserInfoServiceImpl.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserRankingsServiceImpl.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserShareGoodsRecordServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java 24 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/integral/IntegralTaskClassServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/integral/IntegralTaskRecordServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/invite/ThreeSaleSerivceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/invite/UserGetIntegralFromOrderRecordServiceImpl.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/impl/user/tb/UserExtraTaoBaoInfoServiceImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/inter/homemodule/SpecialService.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/inter/order/UserOrderWeiQuanRecordService.java 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/inter/user/SpreadUserImgService.java 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/inter/user/UserInfoService.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/service/manger/HongBaoV2AddManager.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/util/jd/JDUtil.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/util/rocketmq/consumer/user/InvitePictureChangeMessageListener.java 62 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/resource/rocket/consumer.xml 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/resource/rocket/system-coupon-consumer.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
fanli/src/main/java/com/yeshi/fanli/controller/admin/UserInfoAdminController.java
@@ -124,7 +124,7 @@
     * @param out
     */
    @RequestMapping(value = "query")
    public void query(String callback, Integer pageIndex, Integer pageSize, String key, Integer keyType, Integer rank,
    public void query(String callback, Integer pageIndex, Integer pageSize, String key, Integer keyType, Integer rank,Integer userType,
            Integer days, String startTime, String endTime, Integer orderMode, Integer type, PrintWriter out) {
        try {
@@ -174,14 +174,14 @@
            }
            List<UserInfoVO> userList = userInfoService.query((pageIndex - 1) * pageSize, pageSize, type, key, keyType,
                    userRank, days, startTime, endTime, orderField, orderMode);
                    userRank, days, startTime, endTime, orderField, orderMode,userType);
            if (userList == null || userList.size() == 0) {
                JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult("暂无相关数据"));
                return;
            }
            long count = userInfoService.queryCount(type, key, keyType, userRank, days, startTime, endTime);
            long count = userInfoService.queryCount(type, key, keyType, userRank, days, startTime, endTime,userType);
            int totalPage = (int) (count % pageSize == 0 ? count / pageSize : count / pageSize + 1);
            PageEntity pe = new PageEntity(pageIndex, pageSize, count, totalPage);
fanli/src/main/java/com/yeshi/fanli/controller/client/v1/RecommendController.java
@@ -1716,7 +1716,7 @@
            JSONObject root = specialService.listCacheSpecialToIndex(acceptData, deviceSex);
            // 2、顶部轮播图
            List<SwiperPicture> topPicList = getSwiperByCard("index_top",acceptData);
            List<SwiperPicture> topPicList = getSwiperByCard("index_top", acceptData);
            if (topPicList == null) {
                topPicList = new ArrayList<SwiperPicture>();
            }
@@ -1728,7 +1728,7 @@
                    && configService.iosOnLining(Integer.parseInt(acceptData.getVersion()))) {
                // 如果IOS当前版本处于审核状态就不返回
            } else {
                invitePicList = getSwiperByCard("index_invite",acceptData);
                invitePicList = getSwiperByCard("index_invite", acceptData);
            }
            if (invitePicList == null) {
@@ -1769,7 +1769,7 @@
            return null;
        }
        List<SwiperPicture> invitePicList = getSwiperByCard("index_invite",acceptData);
        List<SwiperPicture> invitePicList = getSwiperByCard("index_invite", acceptData);
        return invitePicList;
    }
@@ -2554,9 +2554,8 @@
     */
    @RequestMapping(value = "getSpecialActivities")
    public void getSpecialActivities(AcceptData acceptData, Long uid, PrintWriter out, String callback) {
        int platformCode = Constant.getPlatformCode(acceptData.getPlatform());
        List<Special> listSpecial = specialService.listByVersion(0, Integer.MAX_VALUE, "special_activities",
                platformCode, Integer.parseInt(acceptData.getVersion()));
                acceptData.getPlatform(), Integer.parseInt(acceptData.getVersion()));
        List<Special> list = new ArrayList<Special>();
        if (listSpecial != null) {
fanli/src/main/java/com/yeshi/fanli/controller/client/v1/ShareController.java
@@ -1096,7 +1096,7 @@
                    TaoBaoGoodsBrief goods = taoBaoLink.getGoods();
                    if (!com.yeshi.fanli.util.VersionUtil.greaterThan_2_0_2(acceptData.getPlatform(),
                            acceptData.getVersion()))
                        data.put("clickUrl", ShareControllerV2.getERCodeContent(goods, taoBaoLink.getTaoToken()));
                        data.put("clickUrl", ShareControllerV2.getERCodeContent(configService.get("taobao_share_qrcode_text"), goods, taoBaoLink.getTaoToken()));
                    data.put("token", TaoBaoUtil.filterTaoToken(taoBaoLink.getTaoToken()));
@@ -1121,7 +1121,7 @@
                        }
                    }
                    data.put("commentTexts", commentTexts);
                    data.put("wxErCode", ShareControllerV2.getERCodeContent(goods, taoBaoLink.getTaoToken()));
                    data.put("wxErCode", ShareControllerV2.getERCodeContent(configService.get("taobao_share_qrcode_text"), goods, taoBaoLink.getTaoToken()));
                }
            } else if (cid == 4) { // 邀请分享
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/GoodsControllerV2.java
@@ -240,7 +240,7 @@
        LogHelper.test("获取PID耗时:" + (java.lang.System.currentTimeMillis() - startTime));
        final List<TaoBaoGoodsBrief> goodsList = new ArrayList<>();
        // final List<TaoBaoGoodsBrief> goodsList = new ArrayList<>();
        // 是否在服务端进行转链
        boolean convertInServer = configService.isConvertTaoBaoLinkInServer();
@@ -309,7 +309,6 @@
        }
        if (goods != null) {
            goodsList.add(goods);
            final TaoBaoGoodsBrief newGoods = goods;
            ThreadUtil.run(new Runnable() {
                public void run() {
@@ -324,10 +323,7 @@
            });
        }
        TaoBaoGoodsBrief tb = null;
        if (goodsList.size() > 0) {
            tb = goodsList.get(0);
        }
        TaoBaoGoodsBrief tb = goods;
        if (tb == null) {
            out.print(JsonUtil.loadFalseResult(2, "商品不存在"));
@@ -338,15 +334,32 @@
            tb.setImgList(new ArrayList<>());
        }
        tb.getImgList().add(0, tb.getPictUrl());
        // tb.getImgList().add(0, tb.getPictUrl());
        List<String> finalImgList = new ArrayList<>();
        for (String img : tb.getImgList()) {
            finalImgList.add(TbImgUtil.getTBSizeImg(img, 600));
        }
        if (finalImgList.size() == 0) {
            finalImgList.add(tb.getPictUrl());
        }
        if (!StringUtil.isNullOrEmpty(tb.getPictUrlWhite()))
            finalImgList.add(0, tb.getPictUrlWhite());
        // 移除相同图片
        if (finalImgList.size() > 0)
            for (int i = 0; i < finalImgList.size(); i++) {
                if (i < finalImgList.size() - 1)
                    if (TbImgUtil.getTBSizeImg(finalImgList.get(i), 600)
                            .equalsIgnoreCase(TbImgUtil.getTBSizeImg(finalImgList.get(i + 1), 600))) {
                        finalImgList.remove(i--);
                    }
            }
        tb.setImgList(finalImgList);
        // 大淘客商品过滤
        try {
            goods = daTaoKeGoodsDetailService.filterTaoBaoGoods(goods);
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/SearchControllerV2.java
@@ -129,11 +129,9 @@
    @Resource
    private IntegralGetCacheManager integralGetCacheManager;
    @Resource
    private BrandInfoService brandInfoService;
    /**
     * 粘贴板信息推荐
@@ -261,17 +259,17 @@
            if (tb == null)// 淘宝是空值
            {
                String jdId = JDUtil.getJDGoodsId(text);
                // 微信链接
                if (StringUtil.isNullOrEmpty(jdId)) {
                    jdId = JDUtil.getJDGoodsIdByWeiXin(text);
                }
                // 领券短连接
                if (StringUtil.isNullOrEmpty(jdId) && text.contains("u.jd.com")) {
                    jdId = JDUtil.getJDGoodsIdByUJD(text);
                }
                if (!StringUtil.isNullOrEmpty(jdId)) {
                    JDGoods goods = JDApiUtil.getGoodsDetail(Long.parseLong(jdId));
                    if (goods != null) {
@@ -367,8 +365,9 @@
            Gson gson = JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder())
                    .excludeFieldsWithoutExposeAnnotation().setDateFormat("yyyy-MM-dd").create();
            data.put("type", type);
            data.put("goods", gson.toJson(GoodsDetailVOFactory.convertCommonGoods(commonGoods,
                    new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate()))));
            data.put("goods",
                    gson.toJson(GoodsDetailVOFactory.convertCommonGoods(commonGoods, new ConfigParamsDTO(fanLiRate,
                            shareRate, Constant.MAX_REWARD_RATE, hongBaoManageService.getVIPFanLiRate()))));
            out.print(JsonUtil.loadTrueResult(data));
            return;
        }
@@ -491,8 +490,10 @@
                        JSONObject data = new JSONObject();
                        data.put("type", 3);
                        data.put("goods", gson.toJson(GoodsDetailVOFactory.convertTaoBao(goodsBrief,
                                new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate()))));
                        data.put("goods",
                                gson.toJson(GoodsDetailVOFactory.convertTaoBao(goodsBrief,
                                        new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,
                                                hongBaoManageService.getVIPFanLiRate()))));
                        out.print(JsonUtil.loadTrueResult(data));
                        return true;
                    }
@@ -764,7 +765,8 @@
        List<GoodsDetailVO> list = new ArrayList<GoodsDetailVO>();
        BigDecimal fanLiRate = hongBaoManageService.getFanLiRate();
        BigDecimal shareRate = hongBaoManageService.getShareRate();
        ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate());
        ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,
                hongBaoManageService.getVIPFanLiRate());
        for (TaoBaoGoodsBrief goods : taoBaoGoodsBriefs) {
            list.add(GoodsDetailVOFactory.convertTaoBao(goods, paramsDTO));
@@ -782,7 +784,11 @@
            String version = acceptData.getVersion();
            if (("ios".equalsIgnoreCase(platform) && VersionUtil.greaterThan_2_1(platform, version))
                    || ("android".equalsIgnoreCase(platform) && VersionUtil.greaterThan_2_0_2(platform, version))) {
                BrandInfoVO brandInfoVO = brandInfoService.listByAlikeName(key);
                BrandInfoVO brandInfoVO = null;
                try {
                    brandInfoVO = brandInfoService.listByAlikeName(key);
                } catch (Exception e) {
                }
                if (brandInfoVO != null)
                    data.put("shop", JsonUtil.getApiCommonGson().toJson(brandInfoVO));
            } else {
@@ -791,7 +797,8 @@
                        && listShop.get(0).getListGoodsVO().size() > 2) {
                    TaoBaoShopVO taoBaoShop = listShop.get(0);
                    if (("ios".equalsIgnoreCase(platform) && VersionUtil.greaterThan_2_0(platform, version))
                       || ("android".equalsIgnoreCase(platform) && VersionUtil.greaterThan_2_0_1(platform, version))) {
                            || ("android".equalsIgnoreCase(platform)
                                    && VersionUtil.greaterThan_2_0_1(platform, version))) {
                        BrandInfoVO brandInfoVO = new BrandInfoVO();
                        brandInfoVO.setId(taoBaoShop.getId());
                        brandInfoVO.setName(taoBaoShop.getShopName());
@@ -804,7 +811,7 @@
                }
            }
        }
        out.print(JsonUtil.loadTrueResult(data));
    }
@@ -966,7 +973,8 @@
                BigDecimal shareRate = hongBaoManageService.getShareRate();
                Gson gson = JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder())
                        .excludeFieldsWithoutExposeAnnotation().setDateFormat("yyyy-MM-dd").create();
                ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate());
                ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,
                        hongBaoManageService.getVIPFanLiRate());
                for (JDGoods goods : goodsList) {
                    GoodsDetailVO goodsDetailVO = GoodsDetailVOFactory.convertJDGoods(goods, paramsDTO);
@@ -1050,7 +1058,8 @@
            if (goodsList != null && goodsList.size() > 0) {
                BigDecimal fanLiRate = hongBaoManageService.getFanLiRate();
                BigDecimal shareRate = hongBaoManageService.getShareRate();
                ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate());
                ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,
                        hongBaoManageService.getVIPFanLiRate());
                for (PDDGoodsDetail goods : goodsList) {
                    GoodsDetailVO goodsDetailVO = GoodsDetailVOFactory.convertPDDGoods(goods, paramsDTO);
fanli/src/main/java/com/yeshi/fanli/controller/client/v2/ShareControllerV2.java
@@ -219,19 +219,8 @@
        }
    }
    public static String getERCodeContent(TaoBaoGoodsBrief goods, String token) {
        String content = String.format("【%s】%s元", goods.getUserType() == 1 ? "T猫价" : "T宝价",
                MoneyBigDecimalUtil.getWithNoZera(goods.getZkPrice()) + "");
        content += "\n\r";
        if (!StringUtil.isNullOrEmpty(goods.getCouponInfo())) {
            content += String.format("【券后价】%s元", TaoBaoUtil.getAfterUseCouplePrice(goods) + "");
            content += "\n\r";
        }
        content += "------------";
        content += "\n\r";
        content += "復制这条" + token + ",進入Tao宝即可购买";
        return content;
    public static String getERCodeContent(String template, TaoBaoGoodsBrief goods, String token) {
        return template.replace("[淘口令]", token);
    }
    /**
@@ -285,7 +274,8 @@
            if (taoBaoLink != null && taoBaoLink.getGoods() != null && needGoods) {
                ConfigParamsDTO dto = new ConfigParamsDTO(hongBaoManageService.getFanLiRate(),
                        hongBaoManageService.getShareRate(), Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate());
                        hongBaoManageService.getShareRate(), Constant.MAX_REWARD_RATE,
                        hongBaoManageService.getVIPFanLiRate());
                GoodsDetailVO goodsInfo = GoodsDetailVOFactory.convertTaoBao(taoBaoLink.getGoods(), dto);
                shareInfo.setGoodsInfo(goodsInfo);
            }
@@ -362,9 +352,9 @@
            // 测试
            // 2.0.2之前
            if (!VersionUtil.greaterThan_2_0_2(acceptData.getPlatform(), acceptData.getVersion()))
                shareInfo.setClickUrl(getERCodeContent(taoBaoLink.getGoods(), shareInfo.getToken()));
                shareInfo.setClickUrl(getERCodeContent(configService.get("taobao_share_qrcode_text"), taoBaoLink.getGoods(), shareInfo.getToken()));
            shareInfo.setWxErCode(getERCodeContent(taoBaoLink.getGoods(), shareInfo.getToken()));
            shareInfo.setWxErCode(getERCodeContent(configService.get("taobao_share_qrcode_text"), taoBaoLink.getGoods(), shareInfo.getToken()));
            // 提示图文内容
            String imgs = configService.get("goods_share_notify_imgs");
@@ -393,7 +383,7 @@
                }
            }
            out.print(JsonUtil.loadTrueResult(JsonUtil.getSimpleGson().toJson(shareInfo)));
            out.print(JsonUtil.loadTrueResult(JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder()).create().toJson(shareInfo)));
            final TaoBaoLink taobaoLink = taoBaoLink;
            // 异步操作
@@ -651,8 +641,11 @@
        shareInfo.setCommentTexts(new ArrayList<>());
        if (needGoods)
            shareInfo.setGoodsInfo(GoodsDetailVOFactory.convertJDGoods(jdGoods, new ConfigParamsDTO(
                    hongBaoManageService.getFanLiRate(), hongBaoManageService.getShareRate(), Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate())));
            shareInfo
                    .setGoodsInfo(GoodsDetailVOFactory.convertJDGoods(jdGoods,
                            new ConfigParamsDTO(hongBaoManageService.getFanLiRate(),
                                    hongBaoManageService.getShareRate(), Constant.MAX_REWARD_RATE,
                                    hongBaoManageService.getVIPFanLiRate())));
        String shareText = "";
        boolean hasCoupon = false;
@@ -706,7 +699,7 @@
                e1.printStackTrace();
            }
        }
        out.print(JsonUtil.loadTrueResult(JsonUtil.getSimpleGson().toJson(shareInfo)));
        out.print(JsonUtil.loadTrueResult(JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder()).create().toJson(shareInfo)));
        // 异步操作
        final JDGoods goods = jdGoods;
@@ -767,8 +760,11 @@
        shareInfo.setRule(configService.get("share_rule_link_pdd"));
        shareInfo.setPictUrl(goods.getGoodsImageUrl());
        if (needGoods) {
            shareInfo.setGoodsInfo(GoodsDetailVOFactory.convertPDDGoods(goods, new ConfigParamsDTO(
                    hongBaoManageService.getFanLiRate(), hongBaoManageService.getShareRate(),  Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate())));
            shareInfo
                    .setGoodsInfo(GoodsDetailVOFactory.convertPDDGoods(goods,
                            new ConfigParamsDTO(hongBaoManageService.getFanLiRate(),
                                    hongBaoManageService.getShareRate(), Constant.MAX_REWARD_RATE,
                                    hongBaoManageService.getVIPFanLiRate())));
        }
        String template = "";
@@ -828,7 +824,7 @@
                e1.printStackTrace();
            }
        }
        out.print(JsonUtil.loadTrueResult(JsonUtil.getSimpleGson().toJson(shareInfo)));
        out.print(JsonUtil.loadTrueResult(JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder()).create().toJson(shareInfo)));
        // 异步操作
        com.yeshi.fanli.util.ThreadUtil.run(new Runnable() {
@@ -1419,7 +1415,8 @@
        BigDecimal fanLiRate = hongBaoManageService.getFanLiRate();
        BigDecimal shareRate = hongBaoManageService.getShareRate();
        ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,hongBaoManageService.getVIPFanLiRate());
        ConfigParamsDTO paramsDTO = new ConfigParamsDTO(fanLiRate, shareRate, Constant.MAX_REWARD_RATE,
                hongBaoManageService.getVIPFanLiRate());
        Gson gson = JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder())
                .excludeFieldsWithoutExposeAnnotation().setDateFormat("yyyy-MM-dd").create();
fanli/src/main/java/com/yeshi/fanli/dao/BaseDao.java
File was deleted
fanli/src/main/java/com/yeshi/fanli/dao/mybatis/UserInfoMapper.java
@@ -94,11 +94,11 @@
    List<UserInfoVO> query(@Param("start") long start, @Param("count") int count, @Param("userState") Integer userState,
            @Param("key") String key, @Param("keyType") Integer keyType, @Param("userRank") String userRank,
            @Param("days") Integer days, @Param("startTime") String startTime, @Param("endTime") String endTime,
            @Param("orderField") Integer orderField, @Param("orderMode") Integer orderMode);
            @Param("orderField") Integer orderField, @Param("orderMode") Integer orderMode,@Param("userType") Integer userType);
    long queryCount(@Param("userState") Integer userState, @Param("key") String key, @Param("keyType") Integer keyType,
            @Param("userRank") String userRank, @Param("days") Integer days, @Param("startTime") String startTime,
            @Param("endTime") String endTime);
            @Param("endTime") String endTime,@Param("userType") Integer userType);
    /**
     * 统计当前查询结果总金额
fanli/src/main/java/com/yeshi/fanli/dao/mybatis/order/UserOrderWeiQuanRecordMapper.java
@@ -1,8 +1,19 @@
package com.yeshi.fanli.dao.mybatis.order;
import org.apache.ibatis.annotations.Param;
import com.yeshi.fanli.dao.BaseMapper;
import com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord;
public interface UserOrderWeiQuanRecordMapper extends BaseMapper<UserOrderWeiQuanRecord> {
    /**
     * 根据订单信息与用户ID检索
     * @param uid
     * @param tradeId
     * @param sourceType
     * @return
     */
    public UserOrderWeiQuanRecord selectByOrderInfoAndUid(@Param("uid") Long uid,@Param("tradeId") String tradeId,@Param("sourceType") int sourceType);
}
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/UserTopicTagEnum.java
@@ -2,7 +2,9 @@
import com.yeshi.fanli.dto.mq.user.body.IntegralTaskMQMsg;
import com.yeshi.fanli.dto.mq.user.body.InterTokenMQMsg;
import com.yeshi.fanli.dto.mq.user.body.InviteCodeActiveMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserAccountBindingMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInviteMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserRedPackGiftMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserRegisterMQMsg;
@@ -19,7 +21,8 @@
    userRegister(UserRegisterMQMsg.class),//注册
    tokenOutOfDate(InterTokenMQMsg.class),//口令过期
    redPackGiftDrawback(UserRedPackGiftMQMsg.class),// 红包赠送退回
    userInfoUpdate(null); //用户信息修改
    inviteCodeActive(InviteCodeActiveMQMsg.class),//邀请码激活
    userInfoUpdate(UserInfoUpdateMQMsg.class); //用户信息修改
    private final Class<?> clazz;
fanli/src/main/java/com/yeshi/fanli/dto/mq/user/body/InviteCodeActiveMQMsg.java
New file
@@ -0,0 +1,41 @@
package com.yeshi.fanli.dto.mq.user.body;
import java.util.Date;
import com.yeshi.fanli.dto.mq.BaseMQMsgBody;
/**
 * 用户信息修改
 *
 * @author Administrator
 *
 */
public class InviteCodeActiveMQMsg extends BaseMQMsgBody {
    private Long uid;// 用户ID
    private Date createTime;// 时间
    public InviteCodeActiveMQMsg(Long uid, Date createTime) {
        this.uid = uid;
        this.createTime = createTime;
    }
    public InviteCodeActiveMQMsg() {
    }
    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/dto/mq/user/body/UserInfoUpdateMQMsg.java
@@ -28,7 +28,20 @@
    private Long uid;// 用户ID
    private UserInfoUpdateTypeEnum type;// 类型
    private String value;// 值
    private Date createTime;//时间
    private Date createTime;// 时间
    public UserInfoUpdateMQMsg(Long uid, UserInfoUpdateTypeEnum type, String value, Date createTime) {
        super();
        this.uid = uid;
        this.type = type;
        this.value = value;
        this.createTime = createTime;
    }
    public UserInfoUpdateMQMsg() {
        super();
    }
    public Long getUid() {
        return uid;
fanli/src/main/java/com/yeshi/fanli/entity/elme/ElmeOrder.java
@@ -55,8 +55,18 @@
    private Date createTime;
    @Column(name = "eo_update_time")
    private Date updateTime;
    @Column(name = "eo_state")
    private Integer state;//0-失效  1-有效
    
    public Integer getState() {
        return state;
    }
    public void setState(Integer state) {
        this.state = state;
    }
    private Long uid;
    private BigDecimal hongbao;
    private Integer hbState;
fanli/src/main/java/com/yeshi/fanli/job/order/jd/UpdateJDOrderJob.java
@@ -37,9 +37,16 @@
     */
    public void saveJDOrders(List<JDOrder> jdOrderList) {
        for (JDOrder order : jdOrderList) {
            LogHelper.orderInfo("京东订单:" + order.getOrderId()+"-"+order.getValidCode());
            LogHelper.orderInfo("京东订单:" + order.getOrderId() + "-" + order.getValidCode());
            if (order.getValidCode() == 15)// 过滤掉待付款
                continue;
            //防止多个商品拆单问题,爬取
            if (order.getOrderItemList().size() > 1
                    && order.getOrderTime() > System.currentTimeMillis() - 1000 * 60 * 2L) {
                continue;
            }
            try {
                jdOrderService.addJDOrder(order);
                /**
@@ -47,6 +54,7 @@
                 */
                String key = "jd-order-" + order.getOrderId();
                String result = redisManager.getCommonString(key);
                // 判断
                JDOrderCMQManager.getInstance().addJDOrder(order.getOrderId() + "");
                redisManager.cacheCommonString(key, "1", 60 * 60 * 2);// 2小时内不再更新
@@ -63,7 +71,7 @@
    public void updateSoonOrder() {
        if (!Constant.IS_TASK)
            return;
        LogHelper.job("开始爬取京东订单");
        LogHelper.job("开始爬取京东订单");
        long now = System.currentTimeMillis();
        JDOrderResult result = JDApiUtil.getOrderList(1, 200, new Date(now), JDApiUtil.ORDER_TYPE_CREATETIME);
fanli/src/main/java/com/yeshi/fanli/mapping/UserInfoMapper.xml
@@ -278,8 +278,8 @@
        where wx_union_id=#{unionId} AND state = 0
        LIMIT 1
    </select>
    <select id="getEffectiveUserInfoByWXOpenId" resultMap="BaseResultMap">
        select
        <include refid="Base_Column_List" />
@@ -287,7 +287,7 @@
        where wx_open_id=#{wxOpenId} AND state = 0
        LIMIT 1
    </select>
    <select id="getMaxUid" resultType="java.lang.Long">select max(id) from
        yeshi_ec_user
    </select>
@@ -357,6 +357,11 @@
        <if test="userState == 2">
            AND u.`state` =2   <!-- 封禁用户 -->
        </if>
        <if test="userType!=null">
            AND u.type=#{userType}
        </if>
        <if test="startTime != null and startTime !='' ">
            AND DATE_FORMAT(FROM_UNIXTIME(u.createtime/1000),'%Y%m%d')<![CDATA[>=]]>
            DATE_FORMAT(#{startTime},'%Y%m%d')
@@ -427,6 +432,9 @@
        </if>
        <if test="userState == 2">
            AND u.`state` =2   <!-- 封禁用户 -->
        </if>
        <if test="userType!=null">
            AND u.type=#{userType}
        </if>
        <if test="startTime != null and startTime !='' ">
            AND DATE_FORMAT(FROM_UNIXTIME(u.createtime/1000),'%Y%m%d')<![CDATA[>=]]>
@@ -690,9 +698,12 @@
    </select>
    <select id="getUserInfoByInviteCode" resultMap="BaseResultMap">
        SELECT * FROM yeshi_ec_user u
        LEFT JOIN yeshi_ec_user_info_extra uf ON uf.`uie_uid` =    u.`id`
        WHERE uf.`uie_invite_code_vip` = #{inviteCode} OR uf.`uie_invite_code` = #{inviteCode}
        SELECT * FROM
        yeshi_ec_user u
        LEFT JOIN yeshi_ec_user_info_extra uf ON uf.`uie_uid` =
        u.`id`
        WHERE uf.`uie_invite_code_vip` = #{inviteCode} OR
        uf.`uie_invite_code` = #{inviteCode}
        LIMIT 1
    </select>
@@ -721,17 +732,19 @@
        AND u.`wx_open_id` NOT LIKE 'o_b9%'
        LIMIT #{start},#{count}
    </select>
    <select id="getAutoExtractUserTo1212" resultMap="BaseResultMap">
        SELECT u.* FROM (SELECT v2.`hb_uid` FROM `yeshi_ec_hongbao_v2` v2
        WHERE <![CDATA[v2.`hb_create_time` > '2019-01-01' AND v2.`hb_create_time` < '2019-06-18']]>
        GROUP BY hb_uid)h
        LEFT JOIN `yeshi_ec_user_info_extra` t ON t.`uie_uid` = h.hb_uid
        LEFT JOIN  `yeshi_ec_user` u ON u.`id` = t.`uie_uid`
        WHERE <![CDATA[ t.uie_active_time < '2019-06-19']]> AND (t.`uie_mark` IS NULL OR t.`uie_mark` = '')
            AND u.`state` = 0 AND u.`my_hongBao`<![CDATA[> 1]]>
            AND u.`wx_open_id` IS NOT NULL AND <![CDATA[LENGTH(TRIM(u.`wx_open_id`)) > 0]]>
            AND u.`wx_open_id` NOT LIKE 'o_b9%'
        LEFT JOIN `yeshi_ec_user_info_extra` t ON t.`uie_uid`
        = h.hb_uid
        LEFT JOIN `yeshi_ec_user` u ON u.`id` = t.`uie_uid`
        WHERE <![CDATA[ t.uie_active_time < '2019-06-19']]>
        AND (t.`uie_mark` IS NULL OR t.`uie_mark` = '')
        AND u.`state` = 0 AND u.`my_hongBao`<![CDATA[> 1]]>
        AND u.`wx_open_id` IS NOT NULL AND <![CDATA[LENGTH(TRIM(u.`wx_open_id`)) > 0]]>
        AND u.`wx_open_id` NOT LIKE 'o_b9%'
        LIMIT #{start},#{count}
    </select>
fanli/src/main/java/com/yeshi/fanli/mapping/homemodule/SpecialMapper.xml
@@ -408,10 +408,11 @@
        WHERE sp.`b_state` = 0  
            AND IF(sp.b_start_time IS NULL,TRUE, sp.b_start_time<![CDATA[<=]]> NOW()) 
              AND IF(sp.b_end_time IS NULL,TRUE, sp.b_end_time <![CDATA[>=]]> NOW())
              <if test="platform == 1 and versionCode!=null">
              <if test="platform!=null and platform == 1 and versionCode!=null">
              AND IF(sp.`b_min_android_version_code` IS NOT NULL, #{versionCode}<![CDATA[>=]]> sp.b_min_android_version_code,TRUE)
            </if>
            <if test="platform == 2 and versionCode!=null">
            <if test="platform!=null and platform == 2 and versionCode!=null">
              AND IF(sp.`b_min_ios_version_code` IS NOT NULL, #{versionCode}<![CDATA[>=]]> sp.b_min_ios_version_code,TRUE)
            </if>
            <include refid="Sex_Screen" />
fanli/src/main/java/com/yeshi/fanli/mapping/order/UserOrderWeiQuanRecordMapper.xml
@@ -2,54 +2,90 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yeshi.fanli.dao.mybatis.order.UserOrderWeiQuanRecordMapper">
  <resultMap id="BaseResultMap" type="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord">
    <id column="wr_id" property="id" jdbcType="BIGINT"/>
    <result column="wr_source_type" property="sourceType" jdbcType="INTEGER"/>
    <result column="wr_trade_id" property="tradeId" jdbcType="VARCHAR"/>
    <result column="wr_uid" property="uid" jdbcType="BIGINT"/>
    <result column="wr_money" property="money" jdbcType="DECIMAL"/>
    <result column="wr_state" property="state" jdbcType="INTEGER"/>
    <result column="wr_create_time" property="createTime" jdbcType="TIMESTAMP"/>
    <result column="wr_update_time" property="updateTime" jdbcType="TIMESTAMP"/>
  </resultMap>
  <sql id="Base_Column_List">wr_id,wr_source_type,wr_trade_id,wr_uid,wr_money,wr_state,wr_create_time,wr_update_time</sql>
  <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Long">select
    <include refid="Base_Column_List"/>from yeshi_ec_user_order_weiquan_record where wr_id = #{id,jdbcType=BIGINT}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">delete from yeshi_ec_user_order_weiquan_record where wr_id = #{id,jdbcType=BIGINT}</delete>
  <insert id="insert" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord" useGeneratedKeys="true" keyProperty="id">insert into yeshi_ec_user_order_weiquan_record (wr_id,wr_source_type,wr_trade_id,wr_uid,wr_money,wr_state,wr_create_time,wr_update_time) values (#{id,jdbcType=BIGINT},#{sourceType,jdbcType=INTEGER},#{tradeId,jdbcType=VARCHAR},#{uid,jdbcType=BIGINT},#{money,jdbcType=DECIMAL},#{state,jdbcType=INTEGER},#{createTime,jdbcType=TIMESTAMP},#{updateTime,jdbcType=TIMESTAMP})</insert>
  <insert id="insertSelective" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord" useGeneratedKeys="true" keyProperty="id">insert into yeshi_ec_user_order_weiquan_record
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">wr_id,</if>
      <if test="sourceType != null">wr_source_type,</if>
      <if test="tradeId != null">wr_trade_id,</if>
      <if test="uid != null">wr_uid,</if>
      <if test="money != null">wr_money,</if>
      <if test="state != null">wr_state,</if>
      <if test="createTime != null">wr_create_time,</if>
      <if test="updateTime != null">wr_update_time,</if>
    </trim>values
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="id != null">#{id,jdbcType=BIGINT},</if>
      <if test="sourceType != null">#{sourceType,jdbcType=INTEGER},</if>
      <if test="tradeId != null">#{tradeId,jdbcType=VARCHAR},</if>
      <if test="uid != null">#{uid,jdbcType=BIGINT},</if>
      <if test="money != null">#{money,jdbcType=DECIMAL},</if>
      <if test="state != null">#{state,jdbcType=INTEGER},</if>
      <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if>
      <if test="updateTime != null">#{updateTime,jdbcType=TIMESTAMP},</if>
    </trim>
  </insert>
  <update id="updateByPrimaryKey" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord">update yeshi_ec_user_order_weiquan_record set wr_source_type = #{sourceType,jdbcType=INTEGER},wr_trade_id = #{tradeId,jdbcType=VARCHAR},wr_uid = #{uid,jdbcType=BIGINT},wr_money = #{money,jdbcType=DECIMAL},wr_state = #{state,jdbcType=INTEGER},wr_create_time = #{createTime,jdbcType=TIMESTAMP},wr_update_time = #{updateTime,jdbcType=TIMESTAMP} where wr_id = #{id,jdbcType=BIGINT}</update>
  <update id="updateByPrimaryKeySelective" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord">update yeshi_ec_user_order_weiquan_record
    <set>
      <if test="sourceType != null">wr_source_type=#{sourceType,jdbcType=INTEGER},</if>
      <if test="tradeId != null">wr_trade_id=#{tradeId,jdbcType=VARCHAR},</if>
      <if test="uid != null">wr_uid=#{uid,jdbcType=BIGINT},</if>
      <if test="money != null">wr_money=#{money,jdbcType=DECIMAL},</if>
      <if test="state != null">wr_state=#{state,jdbcType=INTEGER},</if>
      <if test="createTime != null">wr_create_time=#{createTime,jdbcType=TIMESTAMP},</if>
      <if test="updateTime != null">wr_update_time=#{updateTime,jdbcType=TIMESTAMP},</if>
    </set> where wr_id = #{id,jdbcType=BIGINT}
  </update>
    <resultMap id="BaseResultMap"
        type="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord">
        <id column="wr_id" property="id" jdbcType="BIGINT" />
        <result column="wr_source_type" property="sourceType" jdbcType="INTEGER" />
        <result column="wr_trade_id" property="tradeId" jdbcType="VARCHAR" />
        <result column="wr_uid" property="uid" jdbcType="BIGINT" />
        <result column="wr_money" property="money" jdbcType="DECIMAL" />
        <result column="wr_state" property="state" jdbcType="INTEGER" />
        <result column="wr_create_time" property="createTime" jdbcType="TIMESTAMP" />
        <result column="wr_update_time" property="updateTime" jdbcType="TIMESTAMP" />
    </resultMap>
    <sql id="Base_Column_List">wr_id,wr_source_type,wr_trade_id,wr_uid,wr_money,wr_state,wr_create_time,wr_update_time
    </sql>
    <select id="selectByPrimaryKey" resultMap="BaseResultMap"
        parameterType="java.lang.Long">
        select
        <include refid="Base_Column_List" />
        from yeshi_ec_user_order_weiquan_record where wr_id =
        #{id,jdbcType=BIGINT}
    </select>
    <select id="selectByOrderInfoAndUid" resultMap="BaseResultMap">
        select
        <include refid="Base_Column_List" />
        from yeshi_ec_user_order_weiquan_record where wr_trade_id =#{tradeId}
        and wr_source_type=#{sourceType} and wr_uid=#{uid}
    </select>
    <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">delete from
        yeshi_ec_user_order_weiquan_record where wr_id = #{id,jdbcType=BIGINT}
    </delete>
    <insert id="insert" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord"
        useGeneratedKeys="true" keyProperty="id">insert into
        yeshi_ec_user_order_weiquan_record
        (wr_id,wr_source_type,wr_trade_id,wr_uid,wr_money,wr_state,wr_create_time,wr_update_time)
        values
        (#{id,jdbcType=BIGINT},#{sourceType,jdbcType=INTEGER},#{tradeId,jdbcType=VARCHAR},#{uid,jdbcType=BIGINT},#{money,jdbcType=DECIMAL},#{state,jdbcType=INTEGER},#{createTime,jdbcType=TIMESTAMP},#{updateTime,jdbcType=TIMESTAMP})
    </insert>
    <insert id="insertSelective" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord"
        useGeneratedKeys="true" keyProperty="id">
        insert into yeshi_ec_user_order_weiquan_record
        <trim prefix="(" suffix=")" suffixOverrides=",">
            <if test="id != null">wr_id,</if>
            <if test="sourceType != null">wr_source_type,</if>
            <if test="tradeId != null">wr_trade_id,</if>
            <if test="uid != null">wr_uid,</if>
            <if test="money != null">wr_money,</if>
            <if test="state != null">wr_state,</if>
            <if test="createTime != null">wr_create_time,</if>
            <if test="updateTime != null">wr_update_time,</if>
        </trim>
        values
        <trim prefix="(" suffix=")" suffixOverrides=",">
            <if test="id != null">#{id,jdbcType=BIGINT},</if>
            <if test="sourceType != null">#{sourceType,jdbcType=INTEGER},</if>
            <if test="tradeId != null">#{tradeId,jdbcType=VARCHAR},</if>
            <if test="uid != null">#{uid,jdbcType=BIGINT},</if>
            <if test="money != null">#{money,jdbcType=DECIMAL},</if>
            <if test="state != null">#{state,jdbcType=INTEGER},</if>
            <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if>
            <if test="updateTime != null">#{updateTime,jdbcType=TIMESTAMP},</if>
        </trim>
    </insert>
    <update id="updateByPrimaryKey" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord">update
        yeshi_ec_user_order_weiquan_record set wr_source_type =
        #{sourceType,jdbcType=INTEGER},wr_trade_id =
        #{tradeId,jdbcType=VARCHAR},wr_uid = #{uid,jdbcType=BIGINT},wr_money =
        #{money,jdbcType=DECIMAL},wr_state =
        #{state,jdbcType=INTEGER},wr_create_time =
        #{createTime,jdbcType=TIMESTAMP},wr_update_time =
        #{updateTime,jdbcType=TIMESTAMP} where wr_id = #{id,jdbcType=BIGINT}
    </update>
    <update id="updateByPrimaryKeySelective" parameterType="com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord">
        update yeshi_ec_user_order_weiquan_record
        <set>
            <if test="sourceType != null">wr_source_type=#{sourceType,jdbcType=INTEGER},</if>
            <if test="tradeId != null">wr_trade_id=#{tradeId,jdbcType=VARCHAR},</if>
            <if test="uid != null">wr_uid=#{uid,jdbcType=BIGINT},</if>
            <if test="money != null">wr_money=#{money,jdbcType=DECIMAL},</if>
            <if test="state != null">wr_state=#{state,jdbcType=INTEGER},</if>
            <if test="createTime != null">wr_create_time=#{createTime,jdbcType=TIMESTAMP},</if>
            <if test="updateTime != null">wr_update_time=#{updateTime,jdbcType=TIMESTAMP},</if>
        </set>
        where wr_id = #{id,jdbcType=BIGINT}
    </update>
</mapper>
fanli/src/main/java/com/yeshi/fanli/service/impl/activity/ActivityServiceImpl.java
@@ -320,7 +320,7 @@
        return activityUserMapper.selectList();
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public RecommendActivity addShareGoodsRecommendActivity(Long activityUid, List<Long> goodsList,
            RecommendActivity activity) throws ActivityException , Exception{
@@ -397,7 +397,7 @@
        return activity;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public RecommendActivity addInviteImgRecommendActivity(Long activityUid, RecommendActivity activity, String url,
             int px, int py, int erCodeSize) throws ActivityException, Exception {
@@ -446,7 +446,7 @@
        return activity;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public RecommendActivity addTextAndImgRecommendActivity(Long activityUid,  List<String> imgList,
            RecommendActivity activity) throws ActivityException, Exception {
@@ -509,7 +509,7 @@
        return recommendActivityMapper.selectByPrimaryKey(id);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public RecommendActivity updateShareGoodsRecommendActivity(Long activityUid,
            List<Long> goodsList, RecommendActivity activity) throws ActivityException , Exception{
@@ -592,7 +592,7 @@
        return activity;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public RecommendActivity updateInviteImgRecommendActivity(Long activityUid, RecommendActivity activity, String url,
            int px, int py, int erCodeSize) throws ActivityException , Exception{
@@ -659,7 +659,7 @@
        return activity;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public RecommendActivity updateTextAndImgRecommendActivity(Long activityUid, List<String> imgList, 
            RecommendActivity activity) throws ActivityException , Exception{
@@ -755,7 +755,7 @@
        return recommendActivityMapper.getRecommendActivityEffectiveCount();
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void upgradeShareGoodsRecommendActivity(Long id) throws ActivityException {
        // 获取商品
fanli/src/main/java/com/yeshi/fanli/service/impl/brand/BrandClassShopServiceImpl.java
@@ -77,7 +77,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public String saveShopInfo(Long cid, List<Long> list) throws BrandClassShopException {
        if (list == null || list.size() == 0) {
            throw new BrandClassShopException(1, "请选择店铺");
@@ -134,7 +134,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void changeShopInfo(MultipartFile file, Long id, Long cid, String shopName, Integer state, Integer top,
            String key) throws BrandClassShopException {
fanli/src/main/java/com/yeshi/fanli/service/impl/config/SystemClientParamsServiceImpl.java
@@ -49,7 +49,7 @@
    }
    
    
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void saveAdd(SystemClientParams scp, List<Long> listId) throws Exception {
        
fanli/src/main/java/com/yeshi/fanli/service/impl/elme/ElmeHongBaoOrderMapServiceImpl.java
@@ -24,7 +24,7 @@
    @Resource
    private ElmeHongBaoOrderMapMapper elmeHongBaoOrderMapMapper;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addHongBaoOrderMap(ElmeHongBaoOrderMap map) throws ElmeHongBaoOrderMapException {
        if (map.getElmeOrder() == null || map.getElmeOrder().getId() == null || map.getHongBao() == null
fanli/src/main/java/com/yeshi/fanli/service/impl/elme/ElmeOrderProcessServiceImpl.java
@@ -52,7 +52,7 @@
    @Resource
    private UserExtraTaoBaoInfoService userExtraTaoBaoInfoService;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void processOrder(ElmeOrder elmeOrder) throws ElmeOrderException {
        try {
@@ -134,7 +134,7 @@
                new BigDecimal(100)));
        if (elmeOrder.getIsSettle() == true)
            hongBao.setPreGetTime(new Date(elmeOrder.getOrderDate().getTime() + 1000 * 60 * 60 * 24 * 15L));
        if (elmeOrder.getPayMoney().compareTo(new BigDecimal(0)) <= 0)
        if (elmeOrder.getPayMoney().compareTo(new BigDecimal(0)) <= 0||(elmeOrder.getState()!=null&&elmeOrder.getState()==0))
            hongBao.setState(HongBaoV2.STATE_SHIXIAO);
        else {
            if (elmeOrder.getIsSettle() == true) {
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/CollectionGoodsV2ServiceImpl.java
@@ -35,7 +35,7 @@
    @Resource
    private CommonGoodsService commonGoodsService;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addCollection(Long uid, TaoBaoGoodsBrief goods) throws CollectionGoodsException {
        if (uid == null || uid == 0)
@@ -66,7 +66,7 @@
    }
    
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addJDCollection(Long uid, JDGoods jdGoods) throws CollectionGoodsException {
        if (uid == null || uid == 0)
@@ -97,7 +97,7 @@
    }
    
    
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addPDDCollection(Long uid, PDDGoodsDetail goods) throws CollectionGoodsException {
        if (uid == null || uid == 0)
@@ -149,7 +149,7 @@
        collectionGoodsV2Mapper.insertSelective(goods);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void cancelCollection(Long uid, Long id) throws CollectionGoodsException {
        if (uid == null || uid == 0)
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/GoodsClassServiceImpl.java
@@ -139,7 +139,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void saveObject(MultipartFile file, GoodsClass record) throws GoodsClassException, Exception {
        String name = record.getName();
@@ -375,7 +375,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void updateOrder(Long id, Integer moveType) throws GoodsClassException {
        if (id == null || moveType == null || (!moveType.equals(1) && !moveType.equals(-1))) {
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/GoodsSubClassServiceImpl.java
@@ -70,7 +70,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteByRootId(Long id) throws Exception {
        List<GoodsSubClass> subClassList = goodsSubClassMapper.queryByRootId(id, null, null);
@@ -82,7 +82,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteByPrimaryKeyBatch(List<String> recordIds) throws Exception {
        if (recordIds != null && recordIds.size() > 0) {
            for (String recordId : recordIds) {
@@ -92,7 +92,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteSub(Long recordId) throws Exception {
        GoodsSubClass goodsSubClass = goodsSubClassMapper.selectByPrimaryKey(recordId);
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/RecommendUserGoodsServiceImpl.java
@@ -30,7 +30,7 @@
    @Resource
    private CommonGoodsService commonGoodsService;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addRecommend(Long uid, String device, String recommendDesc, List<CommonGoods> goodsList)
            throws RecommendUserGoodsException {
fanli/src/main/java/com/yeshi/fanli/service/impl/goods/ShareGoodsTextTemplateServiceImpl.java
@@ -110,7 +110,7 @@
        return null;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void saveCouponTemplate(Long uid, String template) throws ShareGoodsTextTemplateException {
        // 格式验证
@@ -132,7 +132,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void saveCouponTemplateJD(Long uid, String template) throws ShareGoodsTextTemplateException {
        // 格式验证
@@ -154,7 +154,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void saveCouponTemplatePDD(Long uid, String template) throws ShareGoodsTextTemplateException {
        // 格式验证
@@ -176,7 +176,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void saveTaoLiJinTemplate(Long uid, String template) throws ShareGoodsTextTemplateException {
fanli/src/main/java/com/yeshi/fanli/service/impl/help/HelpCenterServiceImpl.java
@@ -267,7 +267,7 @@
    
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteInfoBatchById(List<String> idList) throws HelpCenterException {
        if (idList != null) {
            for (String id : idList) {
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/FloatADServiceImpl.java
@@ -165,7 +165,7 @@
    }
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void updateOrder(Long id, Integer moveType) throws FloatADException {
        
        if (id == null || moveType == null || (!moveType.equals(1) && !moveType.equals(-1))) {
@@ -198,7 +198,7 @@
    }
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteByPrimaryKeyList(List<Long> list) throws Exception{
        
        List<FloatAD> listSwiper = floatADMapper.ListByPrimaryKey(list);
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SpecialCardServiceImpl.java
@@ -169,7 +169,7 @@
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteBatchByPrimaryKey(List<Long> list) throws Exception{
        specialService.deleteBatchByCardID(list);
        return specialCardMapper.deleteBatchByPrimaryKey(list);
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SpecialPlaceImpl.java
@@ -59,7 +59,7 @@
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteByPrimaryKeyList(List<Long> list) throws Exception{
        return specialPlaceMapper.deleteByPrimaryKeyList(list);
    }
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SpecialServiceImpl.java
@@ -285,7 +285,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void updateOrder(Long id, Integer moveType, Integer sex) throws SpecialException {
        if (id == null || moveType == null || (!moveType.equals(1) && !moveType.equals(-1)) || sex == null) {
@@ -337,7 +337,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor = Exception.class)
    public int deleteBatchByPrimaryKey(List<Long> list) throws Exception {
        List<Special> listSpecial = specialMapper.queryByListPrimaryKey(list);
        for (Special special : listSpecial) {
@@ -351,6 +351,15 @@
                COSManager.getInstance().deleteFile(subPicture);
            }
        }
        if (listSpecial != null)
            for (Special special : listSpecial) {
                List<AdActivityVersionControl> versionList = adActivityVersionControlService
                        .listByTypeAndSourceId(AdActivityType.special, special.getId());
                if (versionList != null)
                    for (AdActivityVersionControl control : versionList)
                        adActivityVersionControlService.deleteByPrimaryKey(control.getId());
            }
        return specialMapper.deleteBatchByPrimaryKey(list);
    }
@@ -448,8 +457,10 @@
    @Override
    @Cacheable(value = "specialCache", key = "'listByVersion-'+#start+'-'+#count+'-'+#card+'-'+#platform+'-'+#versionCode")
    public List<Special> listByVersion(long start, int count, String card, Integer platform, Integer versionCode) {
        return specialMapper.listByVersion(start, count, card, platform, versionCode);
    public List<Special> listByVersion(long start, int count, String card, String platform, Integer versionCode) {
        List<Special> specialList = specialMapper.listByPlaceKey(card, null, null, null);
        filterSpecial(specialList, platform, versionCode);
        return specialList;
    }
    /**
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SwiperBannerServiceImpl.java
@@ -68,7 +68,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteBatchByPrimaryKey(List<Long> list) throws Exception {
        
        List<Long> listPicID = new ArrayList<Long>();
fanli/src/main/java/com/yeshi/fanli/service/impl/homemodule/SwiperPictureServiceImpl.java
@@ -214,7 +214,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor = Exception.class)
    public int deleteBatchByPrimaryKey(List<Long> list) throws SwiperPictureException {
        List<SwiperPicture> listSwiper = swiperPictureMapper.queryByListPrimaryKey(list);
@@ -225,6 +225,14 @@
            }
        }
        if (listSwiper != null)
            for (SwiperPicture picture : listSwiper) {
                List<AdActivityVersionControl> versionList = adActivityVersionControlService
                        .listByTypeAndSourceId(AdActivityType.banner, picture.getId());
                if (versionList != null)
                    for (AdActivityVersionControl control : versionList)
                        adActivityVersionControlService.deleteByPrimaryKey(control.getId());
            }
        return swiperPictureMapper.deleteBatchByPrimaryKey(list);
    }
@@ -301,6 +309,12 @@
    public List<SwiperPicture> getByBannerCardAndVersion(String card, String platform, int version) {
        List<SwiperPicture> list = swiperPictureMapper.getByBannerCard(card);
        filterSwipePicture(list, platform, version);
        for (SwiperPicture picture : list) {
            if (picture.isJumpNeedLogin() && picture.getJumpDetail() != null) {
                picture.getJumpDetail().setNeedLogin(true);
            }
        }
        return list;
    }
fanli/src/main/java/com/yeshi/fanli/service/impl/jd/JDGoodsServiceImpl.java
@@ -86,7 +86,7 @@
    @Cacheable(value = "jdSpecialCache", key = "'specialSearch-'+#page+'-'+#cid")
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public List<JDGoods> specialSearch(Integer page, Long cid) throws JDGoodsException {
        if (cid == null) {
            throw new JDGoodsException(1, "分类id为空");
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/BoutiqueAutoRuleServiceImpl.java
@@ -47,13 +47,13 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteByPrimaryKey(Long id) throws BoutiqueAutoRuleException {
        boutiqueAutoRuleMapper.deleteByPrimaryKey(id);
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteBatchByPrimaryKey(List<Long> ids) throws BoutiqueAutoRuleException {
        for (Long id : ids) {
            boutiqueAutoRuleMapper.deleteByPrimaryKey(id);
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/LabelClassServiceImpl.java
@@ -120,7 +120,7 @@
    
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void addBatchClass(GoodsClass goodsClass,List<Long> labIdList) throws Exception {
        
        long recordId = goodsClass.getId();
@@ -194,7 +194,7 @@
    
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void addBatchSubClass(GoodsSubClass goodsSubClass,List<Long> labIdList) throws Exception {
        
        long recordId = goodsSubClass.getId();
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/LabelGoodsServiceImpl.java
@@ -53,14 +53,14 @@
    }
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteBatchById(long[] ids) throws LabelGoodsException{
        return labelGoodsMapper.deleteBatchByPrimaryKey(ids);
    }
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteByGoodsId(List<String> ids) throws LabelGoodsException {
        
        if (ids != null && ids.size() > 0) {
@@ -126,7 +126,7 @@
    
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void addBatchByLabId(TaoBaoGoodsBrief taoBaoGoodsBrief, List<String> labIdList, AdminUser admin) throws Exception {
        
        List<LabelGoods> addList  = new ArrayList<LabelGoods>();
@@ -155,7 +155,7 @@
    
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void batchGoodsAddLables(List<Long> goodsIdList, List<Long> labIdList, AdminUser admin) throws Exception {
        
        /* 商品id 为空  不处理   */ 
@@ -217,7 +217,7 @@
        
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void singleGoodsAddLables(Long goodsId, List<Long> labIdList, AdminUser admin) throws Exception {
        
        /* 商品id 为空  不处理   */ 
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/LabelServiceImpl.java
@@ -49,7 +49,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void insertList(List<Label>  records,AdminUser admin) throws LabelException{
        if (records != null && records.size() > 0) {
            for (Label label : records) {
@@ -96,7 +96,7 @@
    }
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void updateList(List<Label>  records) throws LabelException{
        if (records != null && records.size() > 0) {
            for (Label label : records) {
@@ -125,13 +125,13 @@
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteBatchById(long[] ids) throws LabelException{
        return labelMapper.deleteBatchByPrimaryKey(ids);
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteBatchByPrimaryKey(List<Long> ids) throws LabelException {
        for (Long id : ids) {
            Label label = labelMapper.selectByPrimaryKey(id);
fanli/src/main/java/com/yeshi/fanli/service/impl/lable/QualityFactoryServiceImpl.java
@@ -100,7 +100,7 @@
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void deleteByGoodsId(List<String> ids) throws QualityFactoryException {
        if (ids != null && ids.size() > 0) {
@@ -151,7 +151,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void addBatchTaoBaoGoods(List<TaoBaoGoodsBrief> listTaoBaoGoods, String lableNames, AdminUser admin)
            throws Exception {
@@ -277,7 +277,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void setWeightBatch(List<Long> idList, AdminUser admin, Integer weight, Integer weightSmall,
            Integer weightLarge) throws Exception {
fanli/src/main/java/com/yeshi/fanli/service/impl/money/InviteOrderSubsidyDebtServiceImpl.java
@@ -25,7 +25,7 @@
    @Resource
    private InviteOrderSubsidyDebtRepayHistoryMapper inviteOrderSubsidyDebtRepayHistoryMapper;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addDebt(InviteOrderSubsidyDebt debt) throws InviteOrderSubsidyDebtException {
        if (debt == null || debt.getOriginMoney() == null || debt.getOriginMoney() == null || debt.getUid() == null) {
@@ -37,7 +37,7 @@
        inviteOrderSubsidyDebtMapper.insertSelective(debt);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void repayDebt(Long debtId, BigDecimal money) throws InviteOrderSubsidyDebtException {
        InviteOrderSubsidyDebt debt = inviteOrderSubsidyDebtMapper.selectByPrimaryKeyForUpdate(debtId);
@@ -62,7 +62,7 @@
        inviteOrderSubsidyDebtRepayHistoryMapper.insertSelective(record);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public BigDecimal repayDebtByUid(Long uid, BigDecimal money) throws InviteOrderSubsidyDebtException {
        // 还钱
fanli/src/main/java/com/yeshi/fanli/service/impl/money/UserMoneyDebtServiceImpl.java
@@ -94,7 +94,7 @@
        return userMoneyDebtMapper.selectByTypeAndSourceId(type, sourceId);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void repayDebt(UserMoneyDebt debt, BigDecimal money) throws UserMoneyDebtException {
        if (debt == null || debt.getId() == null)
@@ -207,7 +207,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void repayDebt(Long uid) {
        // 查询是否有欠债
fanli/src/main/java/com/yeshi/fanli/service/impl/money/extract/BindingAccountServiceImpl.java
@@ -117,7 +117,7 @@
        return bindingAccountMapper.deleteByPrimaryKey(id);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void validAlipayAccount(Long uid, String account, String name)
            throws AlipayTransferException, AlipayApiException, AlipayAccountException {
@@ -225,7 +225,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public BindingAccount changeAlipayBindingWithVerify(Long uid, String name, String account)
            throws AlipayTransferException, AlipayApiException, AlipayAccountException {
fanli/src/main/java/com/yeshi/fanli/service/impl/money/extract/ExtractServiceImpl.java
@@ -188,7 +188,7 @@
        return null;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public synchronized void rejectExtract(long id, String reason, AdminUser admin)
            throws ObjectStateException, NotExistObjectException {
        Extract find = extractMapper.selectByPrimaryKey(id);
@@ -541,7 +541,7 @@
        return extractMapper.selectByPrimaryKey(id);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void checkExtract(Long uid) throws ExtractException {
        BigDecimal compensateMoney = extractMapper.computeCompensateByUid(uid);
fanli/src/main/java/com/yeshi/fanli/service/impl/money/tb/TaoBaoWeiQuanDrawBackServiceImpl.java
@@ -96,7 +96,7 @@
                taoBaoWeiQuanDrawBack.getUser().getId());
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private void addDebt(Long uid, Long hbId, BigDecimal money) throws UserMoneyDebtException {
        UserMoneyDebt debt = new UserMoneyDebt();
        debt.setBeiZhu(null);
@@ -124,7 +124,7 @@
        return money;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void doWeiQuanFanli(String orderId) throws TaoBaoWeiQuanException {
        if (StringUtil.isNullOrEmpty(orderId))
@@ -305,7 +305,7 @@
        return mainHongBaoList;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void doWeiQuanShare(String orderId) throws TaoBaoWeiQuanException {
        if (StringUtil.isNullOrEmpty(orderId))
@@ -444,7 +444,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void doWeiQuanInvite(String orderId) throws TaoBaoWeiQuanException {
        if (StringUtil.isNullOrEmpty(orderId))
fanli/src/main/java/com/yeshi/fanli/service/impl/msg/UserSystemMsgServiceImpl.java
@@ -35,7 +35,7 @@
    @Resource
    private SystemZnxService systemZnxService;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addUserSystemMsg(Long uid, UserSystemMsgTypeEnum type, String title, String content, int timeTag,
            SystemZnx sz) throws UserSystemMsgException {
fanli/src/main/java/com/yeshi/fanli/service/impl/order/CommonOrderServiceImpl.java
@@ -872,7 +872,7 @@
        return commonOrderMapper.listBySourceTypeAndOrderNo(sourceType, orderId);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public List<CommonOrderAddResultDTO> addTaoBaoOrder(List<TaoBaoOrder> taoBaoOrders, Long uid)
            throws CommonOrderException {
@@ -934,7 +934,7 @@
        return commonOrderList;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public List<CommonOrderAddResultDTO> addPDDOrder(List<PDDOrder> pddOrderList, Long uid)
            throws CommonOrderException {
@@ -984,7 +984,7 @@
        return commonOrderList;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public List<CommonOrderAddResultDTO> addJDOrder(JDOrder jdOrder, Long uid) throws CommonOrderException {
        List<CommonOrderAddResultDTO> commonOrderList = new ArrayList<>();
@@ -1054,7 +1054,7 @@
     * 
     * @param commonOrder
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private CommonOrderAddResultDTO addCommonOrder(CommonOrder commonOrder) throws CommonOrderException {
        // 判断商品是否存在
        if (commonOrder == null)
fanli/src/main/java/com/yeshi/fanli/service/impl/order/HongBaoV2ServiceImpl.java
@@ -146,7 +146,7 @@
        return hongBaoV2Mapper.selectByPrimaryKey(id);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public int addHongBao(List<CommonOrder> commonOrderList, int type) throws HongBaoException, UserAccountException {
        Set<Integer> stateSet = new HashSet<>();// 订单状态Set
@@ -276,7 +276,7 @@
        return CommonOrder.STATE_SX;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private boolean updateHongBao(HongBaoOrder hongBaoOrder, CommonOrder commonOrder, int type,
            Map<Integer, HongBaoOrder> notificationMap) throws HongBaoException, UserAccountException {
        System.out.println(commonOrder.getOrderNo());
@@ -663,7 +663,7 @@
        return true;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private void saveHongBao(CommonOrder commonOrder, int type, Map<Integer, HongBaoOrder> notificationMap)
            throws HongBaoException, UserAccountException {
        if (type == HongBaoV2.TYPE_ZIGOU) {// 获取自购的返利比例
fanli/src/main/java/com/yeshi/fanli/service/impl/order/InviteOrderSubsidyServiceImpl.java
@@ -65,7 +65,7 @@
        return inviteOrderSubsidyMapper.getByOrderNoAndTypeForUpdate(uid, orderNo, type);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private void addOrderSubsidy(InviteOrderSubsidy orderSubsidy) throws InviteOrderSubsidyException {
        if (orderSubsidy.getMoney() == null || StringUtil.isNullOrEmpty(orderSubsidy.getOrderNo())
                || orderSubsidy.getSourceType() == null || orderSubsidy.getUid() == null)
@@ -93,7 +93,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addOrUpdateByOrder(String orderId, int sourceType) throws InviteOrderSubsidyException {
        List<HongBaoOrder> list = hongBaoOrderService.listByOrderIdAndSourceType(orderId, sourceType);
fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderMoneySettleServiceImpl.java
@@ -114,7 +114,7 @@
    @Resource
    private HongBaoV2SettleTempService hongBaoV2SettleTempService;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void inviteSettleTB(Long uid) throws OrderMoneySettleException {
        // 查询UID的一二级邀请赚
@@ -179,7 +179,7 @@
        System.out.println(new Gson().toJson(mqMsg));
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void inviteSettleJD(Long uid) throws OrderMoneySettleException {
        // 查询UID的一二级邀请赚
@@ -238,7 +238,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void inviteSettlePDD(Long uid) throws OrderMoneySettleException {
        // 查询UID的一二级邀请赚
@@ -297,7 +297,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void shareSettleTB(Long uid) throws OrderMoneySettleException {
        /**
@@ -342,7 +342,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void shareSettleJD(Long uid) throws OrderMoneySettleException {
        /**
@@ -383,7 +383,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void shareSettlePDD(Long uid) throws OrderMoneySettleException {
        /**
@@ -424,7 +424,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void ziGouSettle(String orderId, int sourceType, String taskKey) throws OrderMoneySettleException {
        // 查询同一订单号的红包
@@ -956,7 +956,7 @@
     * @param orderId
     * @param sourceType
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void inviteSubsidySettle(Long uid, String taskKey) throws OrderMoneySettleException {
        // 查询key
fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderProcessServiceImpl.java
@@ -263,6 +263,13 @@
            elmeOrder.setIsSettle(true);
        else
            elmeOrder.setIsSettle(false);
        if (!taoBaoOrder.getOrderState().equalsIgnoreCase("订单失效"))
            elmeOrder.setState(1);
        else {
            elmeOrder.setState(0);
            elmeOrder.setPayMoney(new BigDecimal(0));
        }
        elmeOrder.setTrackPid(
                String.format("mm_124933865_%s_%s", taoBaoOrder.getSourceMediaId(), taoBaoOrder.getAdPositionId()));
        if (!StringUtil.isNullOrEmpty(taoBaoOrder.getRelationId())) {
@@ -284,7 +291,7 @@
                } catch (ElmeOrderException e) {
                    e.printStackTrace();
                }
            }
        }
    }
@@ -410,7 +417,7 @@
    private HongBaoOrderMapper hongBaoOrderMapper;
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void fanli(HongBaoV2 hb1) throws TaoBaoWeiQuanException {
        // 查询最新的红包数据
        hb1 = hongBaoV2Mapper.selectByPrimaryKeyForUpdate(hb1.getId());
@@ -1194,9 +1201,9 @@
    @Resource
    private ElmeOrderService elmeOrderService;
    @Resource
    private ElmeOrderProcessService elmeOrderProcessService;
    /**
     * 获取饿了么可以返利的红包
     * 
fanli/src/main/java/com/yeshi/fanli/service/impl/order/OrderRepairServiceImpl.java
@@ -147,7 +147,7 @@
    @Resource
    private ExtractCheckCompensateMapper extractCheckCompensateMapper;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void repairOrder(String orderId) throws Exception {
        // 比较CommonOrder与TaoBaoOrder的预估收益
@@ -391,7 +391,7 @@
    }
    // 修改订单信息
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private void updateOrderInfo(TaoBaoOrder taoBaoOrder, Long commonOrderId) throws Exception {
        HongBaoOrder hongBaoOrder = hongBaoOrderService.selectDetailByCommonOrderId(commonOrderId);
        CommonOrder newCommonOrder = TaoBaoOrderUtil.convert(taoBaoOrder);
@@ -598,7 +598,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void addOrder(CommonOrder commonOrder, int type, Long firstUid, Long secondUid) throws Exception {
        // 增加commonOrder
        commonOrder.setCreateTime(commonOrder.getThirdCreateTime());
@@ -960,7 +960,7 @@
        return orderInfoMap.get(orderId);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void repireFirstAndSecondLevel(String orderId) throws Exception {
        repireFirstShare(orderId);
fanli/src/main/java/com/yeshi/fanli/service/impl/order/UserOrderWeiQuanRecordServiceImpl.java
@@ -1,54 +1,69 @@
package com.yeshi.fanli.service.impl.order;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.Date;
import java.util.List;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.yeshi.fanli.dao.mybatis.order.UserOrderWeiQuanRecordMapper;
import com.yeshi.fanli.dto.HongBaoDTO;
import com.yeshi.fanli.entity.bus.user.HongBaoV2;
import com.yeshi.fanli.entity.order.CommonOrder;
import com.yeshi.fanli.entity.order.HongBaoOrder;
import com.yeshi.fanli.entity.order.UserOrderWeiQuanRecord;
import com.yeshi.fanli.entity.taobao.TaoBaoWeiQuanDrawBack;
import com.yeshi.fanli.entity.taobao.TaoBaoWeiQuanOrder;
import com.yeshi.fanli.service.inter.money.tb.TaoBaoWeiQuanDrawBackService;
import com.yeshi.fanli.service.inter.order.CommonOrderService;
import com.yeshi.fanli.service.inter.order.HongBaoOrderService;
import com.yeshi.fanli.service.inter.order.HongBaoV2Service;
import com.yeshi.fanli.service.inter.order.UserOrderWeiQuanRecordService;
import com.yeshi.fanli.service.inter.order.tb.TaoBaoWeiQuanOrderService;
import com.yeshi.fanli.util.MoneyBigDecimalUtil;
import com.yeshi.fanli.util.Constant;
@Service
public class UserOrderWeiQuanRecordServiceImpl implements UserOrderWeiQuanRecordService {
    @Resource
    private UserOrderWeiQuanRecordMapper userOrderWeiQuanRecordMapper;
    @Resource
    private TaoBaoWeiQuanOrderService taoBaoWeiQuanOrderService;
    @Resource
    private TaoBaoWeiQuanDrawBackService taoBaoWeiQuanDrawBackService;
    @Resource
    private HongBaoV2Service hongBaoV2Service;
    @Resource
    private CommonOrderService commonOrderService;
    @Resource
    private HongBaoOrderService hongBaoOrderService;
    @Override
    public void syncPrevious() {
        BigDecimal zero = new BigDecimal(0);
        for (int page = 1; page < Integer.MAX_VALUE; page++) {
            List<TaoBaoWeiQuanOrder> list = taoBaoWeiQuanOrderService.listByBeginWeiQuan(page, 100);
            if (list == null || list.isEmpty())
            if (list == null || list.isEmpty())
                break;
            for (TaoBaoWeiQuanOrder weiQuanOrder: list) {
            for (TaoBaoWeiQuanOrder weiQuanOrder : list) {
                String orderItemId = weiQuanOrder.getOrderItemId();
                List<HongBaoDTO> listV2 = hongBaoV2Service.listByOrderTradeId(orderItemId);
                for (HongBaoDTO hongBaoV2: listV2) {
                for (HongBaoDTO hongBaoV2 : listV2) {
                    Long uid = hongBaoV2.getUserInfo().getId();
                    TaoBaoWeiQuanDrawBack drawBack= taoBaoWeiQuanDrawBackService.selectByOrderItemIdAndUid(orderItemId, uid);
                    TaoBaoWeiQuanDrawBack drawBack = taoBaoWeiQuanDrawBackService.selectByOrderItemIdAndUid(orderItemId,
                            uid);
                    int state = 0;
                    BigDecimal money = null;
                    if (drawBack != null) {
@@ -58,18 +73,18 @@
                            money = drawBackMoney;
                        }
                    }
                    if (money == null) {
                        // (维权金额/结算金额)   * 返利金额
                        // (维权金额/结算金额) * 返利金额
                        BigDecimal wqmoney = weiQuanOrder.getMoney();
                        money = wqmoney.multiply(hongBaoV2.getMoney())
                                .divide(hongBaoV2.getSettlement(), 2, BigDecimal.ROUND_DOWN);
                        // 大于返利金额  则等于返利金额
                        money = wqmoney.multiply(hongBaoV2.getMoney()).divide(hongBaoV2.getSettlement(), 2,
                                BigDecimal.ROUND_UP);
                        // 大于返利金额 则等于返利金额
                        if (money.compareTo(hongBaoV2.getMoney()) > 0)
                            money = hongBaoV2.getMoney();
                    }
                    UserOrderWeiQuanRecord weiQuanRecord = new UserOrderWeiQuanRecord();
                    weiQuanRecord.setUid(uid);
                    weiQuanRecord.setSourceType(1); // 淘宝
@@ -82,6 +97,59 @@
            }
        }
    }
    @Transactional(rollbackFor = Exception.class)
    @Override
    public void addTaoBaoWeiQuan(TaoBaoWeiQuanOrder order) {
        if (!order.getState().contains("维权成功"))
            return;
        // 查询是否存在红包
        CommonOrder commonOrder = commonOrderService.selectBySourceTypeAndTradeId(Constant.SOURCE_TYPE_TAOBAO,
                order.getOrderItemId());
        if (commonOrder == null)
            return;
        HongBaoOrder hongBaoOrder = hongBaoOrderService.selectDetailByCommonOrderId(commonOrder.getId());
        if (hongBaoOrder == null || hongBaoOrder.getHongBaoV2() == null)
            return;
        BigDecimal settleMoney = hongBaoOrder.getCommonOrder().getSettlement();
        HongBaoV2 mainHongBao = hongBaoOrder.getHongBaoV2();
        UserOrderWeiQuanRecord ur = userOrderWeiQuanRecordMapper.selectByOrderInfoAndUid(
                mainHongBao.getUserInfo().getId(), order.getOrderItemId(), Constant.SOURCE_TYPE_TAOBAO);
        if (ur == null) {
            UserOrderWeiQuanRecord record = new UserOrderWeiQuanRecord();
            record.setCreateTime(new Date());
            record.setMoney(hongBaoOrder.getHongBaoV2().getMoney().multiply(order.getMoney()).divide(settleMoney, 2,
                    RoundingMode.UP));
            record.setSourceType(Constant.SOURCE_TYPE_TAOBAO);
            record.setState(0);
            record.setTradeId(order.getOrderItemId());
            record.setUid(hongBaoOrder.getHongBaoV2().getUserInfo().getId());
            if (record.getMoney().compareTo(hongBaoOrder.getHongBaoV2().getMoney()) > 0)
                record.setMoney(hongBaoOrder.getHongBaoV2().getMoney());
            userOrderWeiQuanRecordMapper.insertSelective(record);
        }
        List<HongBaoV2> children = hongBaoV2Service.listChildrenById(mainHongBao.getId());
        for (HongBaoV2 v2 : children) {
            UserOrderWeiQuanRecord record = userOrderWeiQuanRecordMapper.selectByOrderInfoAndUid(
                    v2.getUserInfo().getId(), order.getOrderItemId(), Constant.SOURCE_TYPE_TAOBAO);
            if (record == null) {
                record = new UserOrderWeiQuanRecord();
                record.setCreateTime(new Date());
                record.setMoney(v2.getMoney().multiply(order.getMoney()).divide(settleMoney, 2, RoundingMode.UP));
                record.setSourceType(Constant.SOURCE_TYPE_TAOBAO);
                record.setState(0);
                record.setTradeId(order.getOrderItemId());
                record.setUid(v2.getUserInfo().getId());
                if (record.getMoney().compareTo(v2.getMoney()) > 0)
                    record.setMoney(v2.getMoney());
                userOrderWeiQuanRecordMapper.insertSelective(record);
            }
        }
    }
}
fanli/src/main/java/com/yeshi/fanli/service/impl/order/jd/JDOrderServiceImpl.java
@@ -22,7 +22,7 @@
    @Resource
    private JDOrderMapper jdOrderMapper;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addJDOrder(JDOrder order) throws JDOrderException {
        if (order == null)
fanli/src/main/java/com/yeshi/fanli/service/impl/order/tb/TaoBaoWeiQuanOrderServiceImpl.java
@@ -13,6 +13,7 @@
import com.yeshi.fanli.entity.order.CommonOrder;
import com.yeshi.fanli.entity.taobao.TaoBaoWeiQuanOrder;
import com.yeshi.fanli.service.inter.order.CommonOrderService;
import com.yeshi.fanli.service.inter.order.UserOrderWeiQuanRecordService;
import com.yeshi.fanli.service.inter.order.msg.MsgOrderDetailService;
import com.yeshi.fanli.service.inter.order.msg.UserOrderMsgNotificationService;
import com.yeshi.fanli.service.inter.order.tb.TaoBaoWeiQuanOrderService;
@@ -31,6 +32,9 @@
    @Resource
    private CommonOrderService commonOrderService;
    @Resource
    private UserOrderWeiQuanRecordService userOrderWeiQuanRecordService;
    @Override
    public void addWeiQuanOrder(TaoBaoWeiQuanOrder order) {
@@ -65,6 +69,7 @@
                        updateCommonOrder.setState(CommonOrder.STATE_WQ);
                        updateCommonOrder.setUpdateTime(new Date());
                        commonOrderService.updateByPrimaryKeySelective(updateCommonOrder);
                        userOrderWeiQuanRecordService.addTaoBaoWeiQuan(taoBaoWeiQuanOrder);
                    }
                    List<MsgOrderDetail> msgList = msgOrderDetailService.listMsgOrderByOrderId(order.getOrderId());
fanli/src/main/java/com/yeshi/fanli/service/impl/pdd/PDDGoodsServiceImpl.java
@@ -110,7 +110,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Cacheable(value = "pddSpecialCache", key = "'specialSearch-'+#page+'-'+#cid")
    public List<PDDGoodsDetail> specialSearch(Integer page, Long cid) throws PDDOrderException {
        if (cid == null) {
fanli/src/main/java/com/yeshi/fanli/service/impl/push/IOSPushServiceImpl.java
@@ -326,7 +326,7 @@
     * 
     * @param json
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void addPushIOSQueue(MessageInfo info, String url, int type, String versionCodes) throws PushException {
        if (Constant.IS_TEST)
fanli/src/main/java/com/yeshi/fanli/service/impl/push/PushCouponServiceImpl.java
@@ -85,7 +85,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void save(PushCoupon record) throws PushCouponException,Exception {
        if (record == null) {
            throw new PushCouponException(1, "参数不正确");
@@ -153,7 +153,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void executePush(Long id) throws Exception, PushCouponException, PushException {
        PushCoupon pushCoupon = selectByPrimaryKey(id);
fanli/src/main/java/com/yeshi/fanli/service/impl/push/PushGoodsServiceImpl.java
@@ -78,7 +78,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void save(PushGoods record, List<Long> goodsIds) throws PushGoodsException, Exception {
        // 定时时间
@@ -127,7 +127,7 @@
        saveGoodsInfo(isAdd, pushId, goodsIds);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void saveGoodsInfo(boolean isAdd, Long pushId, List<Long> goodsIds) throws Exception {
        if (goodsIds == null || goodsIds.size() == 0) {
@@ -201,7 +201,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteBatchByPrimaryKey(List<Long> list) throws Exception {
        /*List<PushGoods> lisState = pushGoodsMapper.listByPushState(list);
fanli/src/main/java/com/yeshi/fanli/service/impl/push/PushInfoServiceImpl.java
@@ -265,7 +265,7 @@
    
    
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void executePush(PushInfo record) throws Exception, PushInfoException, PushException {
        if (PushInfo.STATE_SUCCESS == record.getState()) {
fanli/src/main/java/com/yeshi/fanli/service/impl/redpack/RedPackWinInviteServiceImpl.java
@@ -252,7 +252,7 @@
     * @param orderNo
     * @param bossId
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private void twoStageRewardToBoss(Long bossId, Long teamUid, Date oneStageTime, Integer source, String orderNo)
            throws Exception {
        // 第一阶段完成之后的90天内 ; 队友产生的订单中(自购+分享),邀请人累计产生≥1 元奖金
@@ -305,7 +305,7 @@
     * @param orderNo
     * @param bossId
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private void threeStageRewardToBoss(Long bossId, Long teamUid, Date twoStageTime, Integer source, String orderNo)
            throws Exception {
        // 二、三阶段不可同月
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopGoodsSetPayServiceImpl.java
@@ -34,7 +34,7 @@
        return banLiShopGoodsSetsPayMapper.selectByPrimaryKey(id);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addSetPay(BanLiShopGoodsSetsPay pay) throws BanLiShopGoodsSetPayException {
        if (pay.getId() == null)// 新增
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopGoodsSetServiceImpl.java
@@ -41,7 +41,7 @@
        return banLiShopGoodsSetsMapper.selectByPrimaryKey(id);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addSet(BanLiShopGoodsSets set) throws BanLiShopGoodsSetException, BanLiShopGoodsSetPayException {
        if (set.getId() == null)// 添加
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopOrderPayServiceImpl.java
@@ -119,7 +119,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void payOrderByMoney(Long orderId, BigDecimal money) throws BanLiShopOrderException {
        BanLiShopOrder order = banLiShopOrderService.selectByPrimaryKeyForUpdate(orderId);
@@ -164,7 +164,7 @@
    private void paySuccess(BanLiShopOrder order) {
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void refund(Long orderId) throws BanLiShopOrderException {
        // 订单退款
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopOrderServiceImpl.java
@@ -96,7 +96,7 @@
    private RedPackForbidService redPackForbidService;
    
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addOrder(BanLiShopOrder order) throws BanLiShopOrderException {
        // 查询必要的参数是否添加
@@ -224,7 +224,7 @@
        banLiShopOrderMapper.updateByPrimaryKeySelective(order);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void payOrderByHongBao(Long orderId) throws BanLiShopOrderException, RedPackBalanceException {
        BanLiShopOrder order = banLiShopOrderMapper.selectByPrimaryKeyForUpdate(orderId);
fanli/src/main/java/com/yeshi/fanli/service/impl/taobao/TaoBaoBuyRelationMapServiceImpl.java
@@ -21,7 +21,7 @@
    @Resource
    private TaoBaoBuyRelationMapMapper taoBaoBuyRelationMapMapper;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public String getRelationId(Long uid) throws TaoBaoBuyRelationMapException {
        TaoBaoBuyRelationMap relationMap = taoBaoBuyRelationMapMapper.selectByUid(uid);
fanli/src/main/java/com/yeshi/fanli/service/impl/taobao/TaoBaoGoodsUpdateServiceImpl.java
@@ -118,7 +118,7 @@
        shareHotGoodsService.deleteByGoodsId(auctionId);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void updateTaoBaoGoods(TaoBaoGoodsBrief goods) throws TaobaoGoodsUpdateException {
        if (goods == null)
fanli/src/main/java/com/yeshi/fanli/service/impl/tlj/UserTaoLiJinNewbiesServiceImpl.java
@@ -345,7 +345,7 @@
    }
    
    
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private String createTaoLiJin(Long auctionId, BigDecimal perface, int totalNum, String pid) throws UserTaoLiJinNewbiesException {
        SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
        SimpleDateFormat formatStr = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
fanli/src/main/java/com/yeshi/fanli/service/impl/tlj/UserTaoLiJinRecordServiceImpl.java
@@ -124,7 +124,7 @@
        return userTaoLiJinRecordMapper.selectByPrimaryKey(id);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public UserTaoLiJinRecord createSelfBuyTaoLiJin(Long uid, BigDecimal couplePrice, TaoBaoGoodsBrief goods)
            throws UserTaoLiJinRecordException {
@@ -175,7 +175,7 @@
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public UserTaoLiJinRecord createShareTaoLiJin(Long uid, int totalNum, TaoBaoGoodsBrief goods)
            throws UserTaoLiJinRecordException {
@@ -234,7 +234,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public UserTaoLiJinRecord createUserTaoLiJin(int origin, Long uid, Long auctionId, BigDecimal perface, int totalNum,
            String name, Date sendStartTime, Date sendEndTime, Date useStartTime, Date useEndTime, String pid)
            throws UserTaoLiJinRecordException {
fanli/src/main/java/com/yeshi/fanli/service/impl/user/SpreadUserImgServiceImpl.java
@@ -473,6 +473,5 @@
        String rootPath=Thread.currentThread().getContextClassLoader().getResource("").getPath();   
        rootPath = rootPath.substring(1,rootPath.indexOf("WEB-INF"));   
        return rootPath;
    }
    }
}
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserAccountServiceImpl.java
@@ -122,7 +122,7 @@
    @Resource
    private UserInfoModifyRecordService userInfoModifyRecordService;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public LoginResult login(HttpServletRequest request, AcceptData acceptData, Boolean first, String appId,
            String code, String phone, UserInfo tbUserInfo, boolean wxinstall, int loginType)
@@ -380,7 +380,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public LoginResult loginNoInstallWX(AcceptData acceptData, String appId, String code, String phone,
            UserInfo tbUserInfo, int loginType) throws UserAccountException {
@@ -503,7 +503,7 @@
        connectUsers(mainUser, lessUser);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void connectUsers(UserInfo mainUser, UserInfo lessUser) throws UserAccountException {
        mainUser = userInfoMapper.selectByPrimaryKeyForUpdate(mainUser.getId());
@@ -670,7 +670,7 @@
        userInfoMapper.updateByPrimaryKeySelective(userInfo);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void register(UserInfo userInfo) throws UserAccountException {
        if (!StringUtil.isNullOrEmpty(userInfo.getPhone())) {
@@ -975,7 +975,7 @@
        return user.getPortrait();
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public UserInfo loginPhone(HttpServletRequest request, int loginType, String vcode, String phone, String appId)
            throws UserAccountException {
@@ -1075,7 +1075,7 @@
        throw new UserAccountException(10, "请稍后再试");
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public UserInfo loginWinXin(HttpServletRequest request, AcceptData acceptData, int loginType, String code,
            String appId) throws UserAccountException {
@@ -1180,7 +1180,7 @@
        throw new UserAccountException(10, "请稍后再试");
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public UserInfo loginWeiXinNew(HttpServletRequest request, AcceptData acceptData, int loginType, String wxCode,
            String appId) throws UserAccountException {
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserGoodsStorageServiceImpl.java
@@ -217,7 +217,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void addCommonGoods(Long uid, Set<Long> ids) throws UserGoodsStorageException {
        if (uid == null) {
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserInfoExtraServiceImpl.java
@@ -19,8 +19,15 @@
import org.yeshi.utils.entity.FileUploadResult;
import org.yeshi.utils.tencentcloud.COSManager;
import com.aliyun.openservices.ons.api.Message;
import com.aliyun.openservices.ons.api.Producer;
import com.google.gson.Gson;
import com.yeshi.fanli.dao.mybatis.user.UserInfoExtraMapper;
import com.yeshi.fanli.dao.mybatis.user.UserRankRecordMapper;
import com.yeshi.fanli.dto.mq.user.UserTopicTagEnum;
import com.yeshi.fanli.dto.mq.user.body.InviteCodeActiveMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg.UserInfoUpdateTypeEnum;
import com.yeshi.fanli.dto.wx.WXAccountInfoDTO;
import com.yeshi.fanli.entity.bus.user.UserInfo;
import com.yeshi.fanli.entity.bus.user.UserInfoExtra;
@@ -43,6 +50,8 @@
import com.yeshi.fanli.util.InviteCodeFilterUtil;
import com.yeshi.fanli.util.StringUtil;
import com.yeshi.fanli.util.account.UserUtil;
import com.yeshi.fanli.util.rocketmq.MQMsgBodyFactory;
import com.yeshi.fanli.util.rocketmq.MQTopicName;
import com.yeshi.fanli.util.wx.WXLoginUtil;
import com.yeshi.fanli.vo.user.UserInfoExtraVO;
@@ -78,6 +87,9 @@
    @Resource
    private UserInviteRecordService userInviteRecordService;
    @Resource(name = "producer")
    private Producer producer;
    @Override
    public UserInfoExtraVO getRankInfo(Long uid) throws UserInfoExtraException, Exception {
@@ -176,7 +188,7 @@
        } else {
            extra.setUserInfo(new UserInfo(uid));
        }
        // 更新等级
        if (isupdateRank) {
            List<UserRank> listRank = userRankService.getAllRank();
@@ -276,7 +288,6 @@
        userInfoExtraMapper.insertSelective(userInfoExtra);
    }
    @Override
    public UserInfoExtra saveUserInfoExtra(UserInfoExtra userInfoExtra) throws UserInfoExtraException {
@@ -313,9 +324,9 @@
    @Override
    @Transactional(rollbackFor = Exception.class)
    public String activateInviteCode(Long uid, String inviteCode) throws UserInfoExtraException {
        if (uid == null || inviteCode == null)
        if (uid == null || inviteCode == null)
            throw new UserInfoExtraException(1, "激活信息不能为空");
        // 被邀请人信息
        UserInfo invitee = userInfoService.selectByPKey(uid);
        if (invitee == null)
@@ -331,7 +342,7 @@
        UserInfo inviter = userInfoService.getUserInfoByInviteCode(inviteCode);
        if (inviter == null)
            throw new UserInfoExtraException(1, "上级邀请码不存在");
        // 绑定关系
        try {
            threeSaleSerivce.bindRelationshipByInviteCode(invitee, inviter);
@@ -346,7 +357,7 @@
        // 生成邀请码
        String mycode = createInviteCode(uid);
        if (StringUtil.isNullOrEmpty(mycode))
        if (StringUtil.isNullOrEmpty(mycode))
            throw new UserInfoExtraException(1, "激活码生成失败");
        UserInfoExtra userInfoExtra = new UserInfoExtra();
@@ -360,6 +371,12 @@
            userInfoExtra.setCreateTime(new Date());
            userInfoExtraMapper.insertSelective(userInfoExtra);
        }
        // 发送激活成功消息
        Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER, UserTopicTagEnum.inviteCodeActive,
                new Gson().toJson(new InviteCodeActiveMQMsg(uid, new Date())));
        producer.send(message);
        return mycode;
    }
@@ -368,7 +385,7 @@
    public void activationInviteWX(WXAccountInfoDTO wxAccount, Long uid, String code) throws UserInfoExtraException {
        if (uid == null || code == null)
            throw new UserInfoExtraException(1, "激活信息不完整");
        UserInfo invitee = userInfoService.selectByPKey(uid);
        if (invitee == null)
            throw new UserInfoExtraException(1, "用户不存在");
@@ -458,9 +475,9 @@
        // 生成邀请码
        String inviteCode = createInviteCode(uid);
        if (StringUtil.isNullOrEmpty(inviteCode))
        if (StringUtil.isNullOrEmpty(inviteCode))
            throw new UserInfoExtraException(1, "激活码生成失败");
        UserInfoExtra userInfoExtra = new UserInfoExtra();
        userInfoExtra.setUserInfo(invitee);
        userInfoExtra.setInviteCode(inviteCode);
@@ -472,6 +489,10 @@
            userInfoExtra.setCreateTime(new Date());
            userInfoExtraMapper.insertSelective(userInfoExtra);
        }
        // 发送激活成功消息
        Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER, UserTopicTagEnum.inviteCodeActive,
                new Gson().toJson(new InviteCodeActiveMQMsg(uid, new Date())));
        producer.send(message);
    }
    @Override
@@ -571,10 +592,11 @@
        }
        // 生成邀请码
        String inviteCode = createInviteCode(uid);;
        if (StringUtil.isNullOrEmpty(inviteCode))
        String inviteCode = createInviteCode(uid);
        ;
        if (StringUtil.isNullOrEmpty(inviteCode))
            throw new UserInfoExtraException(1, "激活码生成失败");
        UserInfoExtra userInfoExtra = new UserInfoExtra();
        userInfoExtra.setUserInfo(invitee);
        userInfoExtra.setInviteCode(inviteCode);
@@ -617,12 +639,12 @@
    public void updateGoldCoin(Long id, Integer goldCoin) {
        userInfoExtraMapper.updateGoldCoin(id, goldCoin);
    }
    @Override
    public void addGoldCoinByUid(Long uid, Integer goldCoin) {
        userInfoExtraMapper.addGoldCoinByUid(uid, goldCoin);
    }
    @Override
    public void updateByPrimaryKeySelective(UserInfoExtra record) {
        userInfoExtraMapper.updateByPrimaryKeySelective(record);
@@ -640,17 +662,17 @@
            // vip邀请码优先
            if (!StringUtil.isNullOrEmpty(userInfoExtra.getInviteCodeVip()))
                return userInfoExtra.getInviteCodeVip();
            if (!StringUtil.isNullOrEmpty(userInfoExtra.getInviteCode()))
                return userInfoExtra.getInviteCode();
            // 是否满足生产邀请码
            int relationshipNum = threeSaleSerivce.getSuccessRelationshipNum(uid);
            if (relationshipNum > 0) {
                try {
                    String inviteCode = createInviteCode(uid);
                    if (!StringUtil.isNullOrEmpty(inviteCode)) {
                        UserInfoExtra extra= new UserInfoExtra();
                        UserInfoExtra extra = new UserInfoExtra();
                        extra.setId(userInfoExtra.getId());
                        extra.setInviteCode(inviteCode);
                        userInfoExtraMapper.updateByPrimaryKeySelective(extra);
@@ -666,12 +688,13 @@
    /**
     * 生产邀请码
     *
     * @param uid
     * @return
     */
    private String createInviteCode(Long uid) {
        String inviteCode = null;
        for (int i = 1; i <= 5; i ++) {
        for (int i = 1; i <= 5; i++) {
            inviteCode = UserUtil.getInviteCode(i, uid);
            long countCode = userInfoExtraMapper.countByInviteCode(inviteCode);
            if (countCode <= 0)
@@ -679,8 +702,7 @@
        }
        return inviteCode;
    }
    @Override
    public long countByRankId(Long rankId) {
        return userInfoExtraMapper.countByRankId(rankId);
@@ -724,11 +746,11 @@
    public UserInfo getUserByInviteCode(String inviteCode) throws UserInfoExtraException {
        if (StringUtil.isNullOrEmpty(inviteCode))
            throw new UserInfoExtraException(1, "邀请码不能为空");
        UserInfo inviter = userInfoService.getUserInfoByInviteCode(inviteCode);
        if (inviter == null)
            throw new UserInfoExtraException(1, "上级邀请码不存在");
        return inviter;
    }
@@ -782,40 +804,44 @@
        userInfoExtraMapper.updateAutoExtract(days);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void updateInviteCodeVip(String inviteCodeVip, Long uid) throws UserInfoExtraException {
        if (inviteCodeVip == null || inviteCodeVip.length() < 4 || inviteCodeVip.length() > 12)
            throw new UserInfoExtraException(1, "邀请码必须为4到12位");
        UserInfoExtra extra = getUserInfoExtra(uid);
        if (extra == null)
            throw new UserInfoExtraException(2, "用户信息不存在");
        if (StringUtil.isNullOrEmpty(extra.getInviteCode()))
            throw new UserInfoExtraException(3, "邀请码尚未激活");
        if (!StringUtil.isNullOrEmpty(extra.getInviteCodeVip()))
            throw new UserInfoExtraException(4, "只能修改一次");
        // 转换成大写
        inviteCodeVip = inviteCodeVip.toUpperCase();
        // 验证特殊码
        if(InviteCodeFilterUtil.isSpecialCode(inviteCodeVip))
        if (InviteCodeFilterUtil.isSpecialCode(inviteCodeVip))
            throw new UserInfoExtraException(5, "邀请码已存在");
        if (inviteCodeVip.equalsIgnoreCase(extra.getInviteCode()))
            throw new UserInfoExtraException(5, "不能为原邀请码");
        long count = userInfoExtraMapper.countByInviteCode(inviteCodeVip);
        if (count > 0)
            throw new UserInfoExtraException(6, "邀请码已存在");
        UserInfoExtra update = new UserInfoExtra();
        update.setId(extra.getId());
        update.setInviteCodeVip(inviteCodeVip);
        update.setUpdateTime(new Date());
        userInfoExtraMapper.updateByPrimaryKeySelective(update);
        //发送邀请码更改成功的消息
        Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER, UserTopicTagEnum.userInfoUpdate,
                new Gson().toJson(new UserInfoUpdateMQMsg(uid, UserInfoUpdateTypeEnum.inviteCode, inviteCodeVip, new Date())));
        producer.send(message);
    }
}
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserInfoModifyRecordServiceImpl.java
@@ -14,6 +14,8 @@
import com.yeshi.fanli.dao.mybatis.user.UserInfoModifyRecordMapper;
import com.yeshi.fanli.dto.mq.user.UserTopicTagEnum;
import com.yeshi.fanli.dto.mq.user.body.UserAccountBindingMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg.UserInfoUpdateTypeEnum;
import com.yeshi.fanli.entity.bus.user.BindingAccount;
import com.yeshi.fanli.entity.bus.user.UserExtraTaoBaoInfo;
import com.yeshi.fanli.entity.bus.user.UserInfo;
@@ -108,9 +110,16 @@
                        mqMsg = new UserAccountBindingMQMsg(uid, UserAccountBindingMQMsg.TYPE_ALIPAY, value,
                                new Date());
                    }
                    Message message =MQMsgBodyFactory.create(MQTopicName.TOPIC_USER,
                            UserTopicTagEnum.userAccountBinding,mqMsg);
                    Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER,
                            UserTopicTagEnum.userAccountBinding, mqMsg);
                    producer.send(message);
                } else {// 修改
                    if (type == ModifyTypeEnum.portrait) {
                        Message message = MQMsgBodyFactory.create(MQTopicName.TOPIC_USER,
                                UserTopicTagEnum.userInfoUpdate, new Gson().toJson(new UserInfoUpdateMQMsg(uid,
                                        UserInfoUpdateTypeEnum.portrait, value, new Date())));
                        producer.send(message);
                    }
                }
            }
        } catch (Exception e) {
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserInfoServiceImpl.java
@@ -318,16 +318,16 @@
    @Override
    public long queryCount(Integer userState, String key, Integer keyType, String userRank, Integer days,
            String startTime, String endTime) {
        return userInfoMapper.queryCount(userState, key, keyType, userRank, days, startTime, endTime);
            String startTime, String endTime,Integer userType) {
        return userInfoMapper.queryCount(userState, key, keyType, userRank, days, startTime, endTime,userType);
    }
    @Override
    public List<UserInfoVO> query(long start, int count, Integer userState, String key, Integer keyType,
            String userRank, Integer days, String startTime, String endTime, Integer orderField, Integer orderMode) {
            String userRank, Integer days, String startTime, String endTime, Integer orderField, Integer orderMode,Integer userType) {
        List<UserInfoVO> userList = userInfoMapper.query(start, count, userState, key, keyType, userRank, days,
                startTime, endTime, orderField, orderMode);
                startTime, endTime, orderField, orderMode,userType);
        if (userList == null || userList.size() == 0) {
            return null;
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserRankingsServiceImpl.java
@@ -62,7 +62,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteBatchById(Long id) throws UserRankingsException {
        return userRankingsMapper.deleteByPrimaryKey(id);
    }
@@ -75,7 +75,7 @@
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public int deleteBatchByPrimaryKey(List<Long> arrayID) throws UserRankingsException {
        for (Long id : arrayID) {
@@ -173,7 +173,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void setRewardtBatch(List<Long> idList, Integer type, Double reward, Double startReward, Double endReward) throws Exception {
        for (Long id : idList) {
@@ -210,7 +210,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void setStateBatch(List<Long> idList, Integer type, Integer state) throws Exception {
        for (Long id : idList) {
@@ -242,7 +242,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void uploadFile(File file) throws Exception {
        List<UserRankings> list = new ArrayList<UserRankings>();
@@ -278,7 +278,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void updateShowID(File file) throws Exception {
        List<String> listID = new ArrayList<String>();
@@ -304,7 +304,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void batchUpNickName(File file) throws Exception {
        List<String> listID = new ArrayList<String>();
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserShareGoodsRecordServiceImpl.java
@@ -329,7 +329,7 @@
     * @param userShareGoodsRecord
     * @param listGoods
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void multipleGoodsShareRecord(Long shareId, List<CommonGoods> listGoods)
            throws UserShareGoodsRecordException {
        // 分享记录
@@ -372,7 +372,7 @@
     * @param userShareGoodsRecord
     * @param listGoods
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public FileUploadResult multipleGoodsShare(UserShareGoodsRecord userShareGoodsRecord,
            List<TaoBaoGoodsBrief> listGoods) throws UserShareGoodsRecordException {
fanli/src/main/java/com/yeshi/fanli/service/impl/user/UserSystemCouponServiceImpl.java
@@ -230,7 +230,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public UserSystemCoupon insertUserCoupon(Long uid, String couponType, String source, BigDecimal percent,
            Boolean needNotify) throws UserSystemCouponException, Exception {
@@ -344,7 +344,7 @@
        return userCoupon;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public List<UserSystemCouponVO> getUserCouponVOList(long start, int count, Long uid, boolean changeJump)
            throws UserSystemCouponException, Exception {
@@ -610,7 +610,7 @@
        return hasCoupon;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public List<UserSystemCouponVO> getOrderCouponList(Long uid) throws UserSystemCouponException, Exception {
@@ -633,7 +633,7 @@
        return getEnableListByCouponId(uid, 1, couponList);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public List<UserSystemCouponVO> getGoodsCouponList(Long uid, Long auctionId)
            throws UserSystemCouponException, Exception {
@@ -955,7 +955,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void useRewardCouponCore(UserSystemCoupon userSystemCoupon, BigDecimal money, BigDecimal hongBao, Long uid,
            Order order) throws Exception {
        org.springframework.transaction.TransactionStatus transactionStatus = transactionManager
@@ -1358,7 +1358,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void updateStateByDrawback(String orderNo) throws Exception {
@@ -1380,7 +1380,7 @@
        sendBackCoupon(record.getUserSystemCoupon(), record);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void updateStateByArrivalAccount(String orderNo) throws Exception {
@@ -1414,7 +1414,7 @@
        return userSystemCouponMapper.getCounponNowInvalid(count);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public boolean updateCouponRecordUsed(Long uid, String orderNo, BigDecimal payment, Long auctionId)
            throws Exception {
@@ -1494,7 +1494,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void copyLotteryPrize(Long uid, int platform, String device) throws Exception {
        return;
@@ -1577,7 +1577,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void randomRewardCoupon(int num, Long uid, String source) throws Exception {
        if (num < 1) {
            return;
@@ -1717,7 +1717,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void exchangeCoupon(Long uid, String couponType, String source, BigDecimal percent)
            throws UserSystemCouponException, Exception {
        if (couponType == null || uid == null) {
@@ -1773,7 +1773,7 @@
        insertSelective(userCoupon);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public List<UserSystemCouponVO> getCouponList(AcceptData acceptData, long start, int count, Long uid)
            throws UserSystemCouponException, Exception {
fanli/src/main/java/com/yeshi/fanli/service/impl/user/integral/IntegralTaskClassServiceImpl.java
@@ -80,7 +80,7 @@
     * @param uid
     * @return
     */
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public Integer finishedDailySign(long uid) throws Exception{
        IntegralTaskClass taskClass = getByUniqueKey(UniqueKeyEnum.dailySign.name());
        if (taskClass == null || taskClass.getState() == null || taskClass.getState() != 1)
fanli/src/main/java/com/yeshi/fanli/service/impl/user/integral/IntegralTaskRecordServiceImpl.java
@@ -252,7 +252,7 @@
        return totalGoldCoin + (userInfoExtra.getGoldCoin() == null ? 0 : userInfoExtra.getGoldCoin());
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public boolean addDetail(Long uid, IntegralTaskRecord record) throws IntegralTaskRecordException {
        Long uid2 = record.getUid();
        if (uid2 == null || uid.longValue() != uid2.longValue())
@@ -350,7 +350,7 @@
        return integralTaskRecordMapper.countGetCountByTaskIdAndDay(taskId, uid, minTime, maxTime);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public IntegralTaskRecord addRecord(IntegralTaskRecord record) throws IntegralTaskRecordException {
        if (record == null)
fanli/src/main/java/com/yeshi/fanli/service/impl/user/invite/ThreeSaleSerivceImpl.java
@@ -86,7 +86,7 @@
        return threeSaleMapper.selectBoss(uid);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void bind(UserInfo worker, UserInfo inviter) throws ThreeSaleException {
        if (worker == null || inviter == null)
            throw new ThreeSaleException(1, "用户信息为空");
@@ -500,7 +500,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void bindRelationshipByInviteCode(UserInfo invitee, UserInfo inviter) throws ThreeSaleException {
        if (invitee == null || inviter == null)
            throw new ThreeSaleException(1, "用户信息为空");
@@ -520,7 +520,7 @@
    }
    @Override
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    public void bindRelationshipByWX(UserInfo invitee, Long inviterId)throws ThreeSaleException {
        if (invitee == null || inviterId == null)
            throw new ThreeSaleException(1, "用户信息为空");
fanli/src/main/java/com/yeshi/fanli/service/impl/user/invite/UserGetIntegralFromOrderRecordServiceImpl.java
@@ -37,7 +37,7 @@
        return userGetIntegralFromOrderRecordMapper.countByRecordInfo(record);
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addRecord(UserGetIntegralFromOrderRecord record) throws UserGetIntegralFromOrderRecordException {
        if (record == null || record.getUid() == null || record.getEventType() == null
fanli/src/main/java/com/yeshi/fanli/service/impl/user/tb/UserExtraTaoBaoInfoServiceImpl.java
@@ -33,7 +33,7 @@
    @Resource
    private UserAccountBindingHistoryService userAccountBindingHistoryService;
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addRelationId(Long uid, String relationId, String taoBaoUid, String nickName, boolean valid)
            throws UserExtraTaoBaoInfoException {
@@ -77,7 +77,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void addSpecialId(Long uid, String specialId, String taoBaoUid, String nickName, boolean valid)
            throws UserExtraTaoBaoInfoException {
@@ -121,7 +121,7 @@
        }
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    @Override
    public void saveUserTaoBaoInfo(Long uid, String relationId, String specialId, String taoBaoUid, String nickName,
            boolean valid) throws UserExtraTaoBaoInfoException {
fanli/src/main/java/com/yeshi/fanli/service/inter/homemodule/SpecialService.java
@@ -107,7 +107,7 @@
     * @param versionCode
     * @return
     */
    public List<Special> listByVersion(long start, int count, String card, Integer platform, Integer versionCode);
    public List<Special> listByVersion(long start, int count, String card, String platform, Integer versionCode);
    /**
fanli/src/main/java/com/yeshi/fanli/service/inter/order/UserOrderWeiQuanRecordService.java
@@ -1,5 +1,7 @@
package com.yeshi.fanli.service.inter.order;
import com.yeshi.fanli.entity.taobao.TaoBaoWeiQuanOrder;
public interface UserOrderWeiQuanRecordService {
    /**
@@ -7,4 +9,11 @@
     */
    public void syncPrevious();
    /**
     * 添加淘宝维权
     *
     * @param order
     */
    public void addTaoBaoWeiQuan(TaoBaoWeiQuanOrder order);
}
fanli/src/main/java/com/yeshi/fanli/service/inter/user/SpreadUserImgService.java
@@ -25,6 +25,7 @@
    /**
     * 用户分享图的数量
     *
     * @param uid
     * @return
     */
@@ -53,17 +54,20 @@
    String getUserSpreadImg(Long uid, String bgImg, int erCodePostionX, int erCodePostionY, int erCodeSize);
    /**
     *  根据图片画二维码
     * 根据图片画二维码
     *
     * @param uid
     * @param bgImg
     * @param inviteCode
     * @return
     * @throws Exception
     */
    String drawInviteQrCodeNew(String bgImg, Long uid, String portrait, Integer pX, Integer pY, Integer size, String inviteCode) throws Exception;
    String drawInviteQrCodeNew(String bgImg, Long uid, String portrait, Integer pX, Integer pY, Integer size,
            String inviteCode) throws Exception;
    /**
     * 邀请图片 问候
     *
     * @param bgImg
     * @param uid
     * @param portrait
@@ -73,12 +77,12 @@
     * @return
     * @throws Exception
     */
    public String getInviteImgToGreet(String bgImg, Long uid, String portrait, String inviteCode, String content, Date date)
            throws Exception;
    public String getInviteImgToGreet(String bgImg, Long uid, String portrait, String inviteCode, String content,
            Date date) throws Exception;
    /**
     * 获取用户要求图列表
     *
     * @param uid
     * @param page
     * @param count
@@ -86,5 +90,4 @@
     * @return
     */
    public List<String> getUserSpreadImgToPage(Long uid, int page, int count, HttpServletRequest request);
}
fanli/src/main/java/com/yeshi/fanli/service/inter/user/UserInfoService.java
@@ -81,10 +81,10 @@
     * @return
     */
    public List<UserInfoVO> query(long start, int count, Integer userState, String key, Integer keyType,
            String userRank, Integer days, String startTime, String endTime, Integer orderField, Integer orderMode);
            String userRank, Integer days, String startTime, String endTime, Integer orderField, Integer orderMode,Integer userType);
    public long queryCount(Integer userState, String key, Integer keyType, String userRank, Integer days,
            String startTime, String endTime);
            String startTime, String endTime,Integer userType);
    public double querySumMoney(String key, Integer userType, Integer days, String startTime, String endTime);
fanli/src/main/java/com/yeshi/fanli/service/manger/HongBaoV2AddManager.java
@@ -213,7 +213,7 @@
        return CommonOrder.STATE_SX;
    }
    @Transactional
    @Transactional(rollbackFor=Exception.class)
    private boolean updateHongBao(HongBaoOrder hongBaoOrder, CommonOrder commonOrder, int type,
            Map<Integer, HongBaoOrder> notificationMap) throws HongBaoException, UserAccountException {
        System.out.println(commonOrder.getOrderNo());
fanli/src/main/java/com/yeshi/fanli/util/jd/JDUtil.java
@@ -29,7 +29,6 @@
import org.yeshi.utils.HttpUtil;
import com.yeshi.fanli.dto.GoodsClassDTO;
import com.yeshi.fanli.dto.douyin.DouYinGoods;
import com.yeshi.fanli.dto.jd.JDCommissionInfo;
import com.yeshi.fanli.dto.jd.JDCouponInfo;
import com.yeshi.fanli.dto.jd.JDPingouInfo;
fanli/src/main/java/com/yeshi/fanli/util/rocketmq/consumer/user/InvitePictureChangeMessageListener.java
New file
@@ -0,0 +1,62 @@
package com.yeshi.fanli.util.rocketmq.consumer.user;
import javax.annotation.Resource;
import org.springframework.stereotype.Component;
import com.aliyun.openservices.ons.api.Action;
import com.aliyun.openservices.ons.api.ConsumeContext;
import com.aliyun.openservices.ons.api.Message;
import com.aliyun.openservices.ons.api.MessageListener;
import com.google.gson.Gson;
import com.yeshi.fanli.dto.mq.user.UserTopicTagEnum;
import com.yeshi.fanli.dto.mq.user.body.InviteCodeActiveMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg;
import com.yeshi.fanli.dto.mq.user.body.UserInfoUpdateMQMsg.UserInfoUpdateTypeEnum;
import com.yeshi.fanli.log.LogHelper;
import com.yeshi.fanli.service.inter.user.SpreadUserImgService;
import com.yeshi.fanli.util.rocketmq.MQTopicName;
/**
 * 用户邀请图改变
 *
 * @author Administrator
 *
 */
@Component
public class InvitePictureChangeMessageListener implements MessageListener {
    @Resource
    private SpreadUserImgService spreadUserImgService;
    @Override
    public Action consume(Message message, ConsumeContext context) {
        LogHelper.mqInfo("consumer-InvitePictureChangeMessageListener", message.getMsgID(), message.getTopic(),
                message.getTag(), new String(message.getBody()));
        String tag = message.getTag();
        if (tag == null)
            tag = "";
        if (MQTopicName.TOPIC_USER.name().equalsIgnoreCase(message.getTopic())) {
            if (tag.equalsIgnoreCase(UserTopicTagEnum.inviteCodeActive.name())) {// 邀请码激活
                InviteCodeActiveMQMsg inviteCodeActiveMQMsg = new Gson().fromJson(new String(message.getBody()),
                        InviteCodeActiveMQMsg.class);
                if (inviteCodeActiveMQMsg != null && inviteCodeActiveMQMsg.getUid() != null)
                    spreadUserImgService.deleteImgUrl(inviteCodeActiveMQMsg.getUid());
                return Action.CommitMessage;
            } else if (tag.equalsIgnoreCase(UserTopicTagEnum.userInfoUpdate.name())) {// 订单统计
                UserInfoUpdateMQMsg userInfoUpdateMQMsg = new Gson().fromJson(new String(message.getBody()),
                        UserInfoUpdateMQMsg.class);
                if (userInfoUpdateMQMsg != null && (userInfoUpdateMQMsg.getType() == UserInfoUpdateTypeEnum.portrait
                        || userInfoUpdateMQMsg.getType() == UserInfoUpdateTypeEnum.inviteCode)) {
                    if (userInfoUpdateMQMsg.getUid() != null)
                        spreadUserImgService.deleteImgUrl(userInfoUpdateMQMsg.getUid());
                }
                return Action.CommitMessage;
            }
        }
        return Action.CommitMessage;
    }
}
fanli/src/main/resource/rocket/consumer.xml
@@ -98,7 +98,8 @@
                    <key>
                        <bean class="com.aliyun.openservices.ons.api.bean.Subscription">
                            <property name="topic" value="TOPIC_ORDER" />
                            <property name="expression" value="orderStatistic||orderFanLiActual||orderStatisticDelay||orderFanLiSeparateByOrderNo" />
                            <property name="expression"
                                value="orderStatistic||orderFanLiActual||orderStatisticDelay||orderFanLiSeparateByOrderNo" />
                        </bean>
                    </key>
                </entry>
@@ -109,7 +110,7 @@
                        <bean class="com.aliyun.openservices.ons.api.bean.Subscription">
                            <property name="topic" value="TOPIC_USER" />
                            <property name="expression"
                                value="inviteSuccess||userAccountBinding||integralTaskFinish||redPackGift" />
                                value="inviteSuccess||userAccountBinding||integralTaskFinish||redPackGift||redPackGiftDrawback" />
                        </bean>
                    </key>
                </entry>
@@ -147,8 +148,8 @@
            </map>
        </property>
    </bean>
    <!-- 订单到账消息订阅 -->
    <bean id="orderMoneyRecievedMessageListener"
        class="com.yeshi.fanli.util.rocketmq.consumer.order.OrderMoneyRecievedMessageListener"></bean>
@@ -179,6 +180,37 @@
        </property>
    </bean>
    <!-- 邀请图修改消息订阅 -->
    <bean id="invitePictureChangeMessageListener"
        class="com.yeshi.fanli.util.rocketmq.consumer.user.InvitePictureChangeMessageListener"></bean>
    <!-- Group ID 订阅同一个 Topic,可以创建多个 ConsumerBean -->
    <bean id="invitePictureChangeConsumer" class="com.aliyun.openservices.ons.api.bean.ConsumerBean"
        init-method="start" destroy-method="shutdown">
        <property name="properties"> <!--消费者配置信息 -->
            <props>
                <prop key="AccessKey">${rocketmq.AccessKey}</prop>
                <prop key="SecretKey">${rocketmq.SecretKey}</prop>
                <prop key="GROUP_ID">GID_INVITE_PICTURE</prop>
                <prop key="NAMESRV_ADDR">${rocketmq.NAMESRV_ADDR}</prop>
                <prop key="ConsumeThreadNums">50</prop>
            </props>
        </property>
        <property name="subscriptionTable">
            <map>
                <!-- 邀请码激活,用户信息修改 -->
                <entry value-ref="invitePictureChangeMessageListener">
                    <key>
                        <bean class="com.aliyun.openservices.ons.api.bean.Subscription">
                            <property name="topic" value="TOPIC_USER" />
                            <property name="expression" value="inviteCodeActive||userInfoUpdate" />
                        </bean>
                    </key>
                </entry>
            </map>
        </property>
    </bean>
</beans>
fanli/src/main/resource/rocket/system-coupon-consumer.xml
@@ -32,7 +32,7 @@
                <entry value-ref="systemCouponMessageListener">
                    <key>
                        <bean class="com.aliyun.openservices.ons.api.bean.Subscription">
                            <property name="topic" value="GID_SYSTEM_COUPON" />
                            <property name="topic" value="TOPIC_USER" />
                            <property name="expression" value="systemCouponDrawback" />
                        </bean>
                    </key>