| | |
| | | doPDDOrderJob();// 拼多多订单处理
|
| | | doImportantTaoBaoGoodsUpdateJob();// 淘宝重要商品的信息更新
|
| | | doHongBaoRecieveIntegralGetJob();// 返利到账,金币增加
|
| | | doPlaceOrderIntegralJob();// 下单赠送金币任务
|
| | | // doPlaceOrderIntegralJob();// 下单赠送金币任务
|
| | | doDouYinDeviceActiveJob();// 抖音设备激活广告监测
|
| | | }
|
| | |
|
| | | }
|
| | |
|
| | | /**
|
| | |
| | | integralTaskRecordService.firstRebateOrderRewardBoss(boss.getId(),
|
| | | order.getUserInfo().getId(), null);
|
| | | }
|
| | | }
|
| | |
|
| | | boss = threeSaleSerivce.getBoss(boss.getId());
|
| | | if (boss != null) {// 判断上级的红包
|
| | | if (hongBaoMoney.get(boss.getId()) == null
|
| | | || hongBaoMoney.get(boss.getId()).compareTo(new BigDecimal("0")) <= 0) {
|
| | | // 补偿金币2级
|
| | | integralTaskRecordService.firstRebateOrderRewardBossSuper(boss.getId(),
|
| | | order.getUserInfo().getId(), null);
|
| | | boss = threeSaleSerivce.getBoss(boss.getId());
|
| | | if (boss != null) {// 判断上级的红包
|
| | | if (hongBaoMoney.get(boss.getId()) == null || hongBaoMoney.get(boss.getId())
|
| | | .compareTo(new BigDecimal("0")) <= 0) {
|
| | | // 补偿金币2级
|
| | | integralTaskRecordService.firstRebateOrderRewardBossSuper(boss.getId(),
|
| | | order.getUserInfo().getId(), null);
|
| | | }
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | |
|
| | | // 抖音
|
| | | public void doDouYinDeviceActiveJob() {
|
| | | LogHelper.test("开始执行:doDouYinDeviceActiveJob");
|
| | | executor.execute(new Runnable() {
|
| | | @Override
|
| | | public void run() {
|
| | | LogHelper.test("开始执行:doDouYinDeviceActiveJob-run");
|
| | | while (true) {
|
| | | Map<String, DouYinDeviceActiveQueueDTO> map = DouYinDeviceActiveCMQManager.getInstance()
|
| | | .consume(16);
|
| | |
| | | String key = its.next();
|
| | | DouYinDeviceActiveQueueDTO active = map.get(key);
|
| | | if (active.getType() == DouYinDeviceActiveQueueDTO.TYPE_AD) {// 抖音
|
| | | DeviceActive deviceActive = deviceActiveService.getFirstActiveInfo(active.getDevice());
|
| | | if (deviceActive != null) {
|
| | | DouYinClickEvent event = douYinClickEventService.selectByAid(active.getAid());
|
| | | if (event != null) {
|
| | | if (event.getOs() == 0)
|
| | | DouYinAdUtil.activeAndroid(event.getCallback(), event.getImei(),
|
| | | deviceActive.getCreateTime().getTime());
|
| | | else if (event.getOs() == 1)
|
| | | DouYinAdUtil.activeIOS(event.getCallback(), event.getIdfa(),
|
| | | deviceActive.getCreateTime().getTime());
|
| | | DouYinClickEvent event = douYinClickEventService.selectByAid(active.getAid());
|
| | | if (event != null) {
|
| | | if (event.getOs() == 0) {
|
| | | DeviceActive deviceActive = deviceActiveService
|
| | | .getFirstActiveInfoByImei(event.getUuid());
|
| | | if (deviceActive != null) {
|
| | | if (event != null) {
|
| | | if (event.getOs() == 0)
|
| | | DouYinAdUtil.activeAndroid(event.getCallback(), event.getImei(),
|
| | | deviceActive.getCreateTime().getTime());
|
| | | else if (event.getOs() == 1)
|
| | | DouYinAdUtil.activeIOS(event.getCallback(), event.getIdfa(),
|
| | | deviceActive.getCreateTime().getTime());
|
| | | }
|
| | | }
|
| | | } else {// TODO 处理IOS
|
| | |
|
| | | }
|
| | | }
|
| | |
|
| | | } else if (active.getType() == DouYinDeviceActiveQueueDTO.TYPE_DEVICE) {// 设备
|
| | | // TODO 兼容IOS
|
| | | if (active.getPlatform() == 1) {
|
| | | DouYinClickEvent event = douYinClickEventService
|
| | | .selectByAndroidId(active.getDevice());
|
| | | if (event != null) {// 回调
|
| | | DeviceActive deviceActive = deviceActiveService
|
| | | .getFirstActiveInfo(active.getDevice());
|
| | | if (deviceActive != null)
|
| | | DouYinAdUtil.activeAndroid(event.getCallback(), event.getImei(),
|
| | | deviceActive.getCreateTime().getTime());
|
| | | }
|
| | | }
|
| | |
|
| | | if (active.getPlatform() == 1) {
|
| | | DeviceActive deviceActive = deviceActiveService
|
| | | .getFirstActiveInfo(active.getDevice());
|
| | | if (deviceActive != null && deviceActive.getImei() != null) {
|
| | | DouYinClickEvent event = douYinClickEventService
|
| | | .selectByUuid(deviceActive.getImei());
|
| | | if (event != null) {// 回调
|
| | | if (deviceActive != null)
|
| | | DouYinAdUtil.activeAndroid(event.getCallback(), event.getImei(),
|
| | | deviceActive.getCreateTime().getTime());
|
| | | }
|
| | | }
|
| | | } else {
|
| | | // TODO 兼容IOS
|
| | | }
|
| | | }
|
| | | DouYinDeviceActiveCMQManager.getInstance().delete(key);
|
| | | }
|
| | | }
|
| | | }
|