yujian
2019-09-09 0d9ac58dc11f54351e5e18dba8e950717d78019f
fanli/src/main/java/com/yeshi/fanli/util/SpringContext.java
@@ -27,10 +27,11 @@
import com.yeshi.fanli.entity.taobao.TaoBaoGoodsBrief;
import com.yeshi.fanli.entity.taobao.TaoBaoOrder;
import com.yeshi.fanli.entity.taobao.TaoBaoWeiQuanOrder;
import com.yeshi.fanli.exception.TaoBaoWeiQuanException;
import com.yeshi.fanli.exception.order.TaoBaoWeiQuanException;
import com.yeshi.fanli.log.LogHelper;
import com.yeshi.fanli.service.inter.hongbao.HongBaoV2Service;
import com.yeshi.fanli.service.inter.hongbao.ThreeSaleSerivce;
import com.yeshi.fanli.service.inter.integral.IntegralGetService;
import com.yeshi.fanli.service.inter.jd.JDOrderService;
import com.yeshi.fanli.service.inter.lable.BoutiqueAutoRuleService;
import com.yeshi.fanli.service.inter.lable.LabelService;
@@ -107,6 +108,9 @@
   @Resource
   private HongBaoV2Service hongBaoV2Service;
   @Resource
   private IntegralGetService integralGetService;
   private static boolean isInited = false;
   public void onApplicationEvent(ContextRefreshedEvent arg0) {
@@ -141,6 +145,7 @@
         doJDOrderJob();// 京东订单处理
         doPDDOrderJob();// 拼多多订单处理
         doImportantTaoBaoGoodsUpdateJob();// 淘宝重要商品的信息更新
         doHongBaoRecieveIntegralGetJob();// 返利到账,金币增加
      }
   }
@@ -707,19 +712,19 @@
                     String key = its.next();
                     Long hongBaoId = map.get(key);
                     try {
                        HongBaoV2 hongBaoV2 = hongBaoV2Service.selectByPrimaryKey(hongBaoId);
                        if (hongBaoV2 != null && hongBaoV2.getState() == HongBaoV2.STATE_YILINGQU) {
                        if (hongBaoV2 != null && hongBaoV2.getState() == HongBaoV2.STATE_YILINGQU
                              && hongBaoV2.getMoney().compareTo(new BigDecimal(0)) > 0) {
                           if (hongBaoV2.getType() == HongBaoV2.TYPE_ZIGOU) {// 自购
                              // TODO 添加加金币事件
                              integralGetService.addRebateOrder(hongBaoV2.getUserInfo().getId());
                           } else if (hongBaoV2.getType() == HongBaoV2.TYPE_SHARE_GOODS) {// 分享赚
                              // TODO 添加加金币事件
                              integralGetService.addShareOrder(hongBaoV2.getUserInfo().getId());
                           } else if (hongBaoV2.getType() == HongBaoV2.TYPE_YIJI
                                 || hongBaoV2.getType() == HongBaoV2.TYPE_SHARE_YIJI) {// 一级邀请赚
                              // TODO 添加加金币事件
                              integralGetService.addInviteOrderLevelOne(hongBaoV2.getUserInfo().getId());
                           } else if (hongBaoV2.getType() == HongBaoV2.TYPE_ERJI
                                 || hongBaoV2.getType() == HongBaoV2.TYPE_SHARE_ERJI) {// 二级邀请赚
                              // TODO 添加加金币事件
                              integralGetService.addInviteOrderLevelOne(hongBaoV2.getUserInfo().getId());
                           }
                        }
                        HongBaoRecieveCMQManager.getInstance()