Bladeren bron

修改快手初次获取数据任务

syh 5 jaren geleden
bovenliggende
commit
c12c65fb3a

+ 2 - 2
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/CallbackController.java

@@ -217,13 +217,13 @@ public class CallbackController {
 
                     //账号绑定
                     bindAccountAuthService.addBindAccount(accountId, KuaishouInterfaceConstant.LOGIN_TYPE_KUAISHOU, advertiserId);
-                   /* Thread t = new Thread() {
+                    Thread t = new Thread() {
                         @Override
                         public void run() {
                             kuaishouInterfaceService.loadKuaishouDataSingle(topOauthToken);
                         }
                     };
-                    t.start();*/
+                    t.start();
                 }
                 return "授权绑定成功";
             }

+ 0 - 2
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/job/ByteDanceCleanMaterialJob.java

@@ -40,8 +40,6 @@ public class ByteDanceCleanMaterialJob implements Job {
                         }
                     });
                 }
-
-
             }
         };
         thread.start();

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/job/BytedanceCreativeDailyReportLoadJob.java

@@ -44,7 +44,7 @@ public class BytedanceCreativeDailyReportLoadJob implements Job {
             executorService.submit(new Runnable() {
                 @Override
                 public void run() {
-                    //4: 获取广告创意信息数据
+                    //获取广告创意信息数据
                     reportService.getAdvertiserCreativeReport(token, getDate, getDate, CtopAdConstant.BYTEDANCE_REPORT_TYPE_DAILY);
                 }
             });

+ 2 - 2
jeecg-boot-module-system/src/main/resources/application-dev.yml

@@ -102,8 +102,8 @@ spring:
       datasource:
         master:
           url: jdbc:mysql://39.106.184.70:3306/jeecg-boot?characterEncoding=UTF-8&useUnicode=true&useSSL=false
-          username: root
-          password: hcst2019
+          username: hcst
+          password: test@20190531
           driver-class-name: com.mysql.jdbc.Driver
           # 多数据源配置
           #multi-datasource1:

+ 5 - 3
jeecg-boot-module-system/src/test/java/org/jeecg/SampleTest.java

@@ -128,15 +128,17 @@ public class SampleTest {
     public void testBakToken() {
         Date getDate = DateUtils.addDay(new Date(), -1);
         QueryWrapper<UserAllocation> queryWrapper = new QueryWrapper<>();
-        queryWrapper.eq("project_id", 215);
+        queryWrapper.eq("project_id", 235);
         List<UserAllocation> allocations = userAllocationService.list(queryWrapper);
         if (null != allocations && allocations.size() > 0) {
             for (UserAllocation allocation : allocations) {
                 CtopOauthToken token = tokenService.getTokenByAccountId(allocation.getAccountId());
-                reportService.getAdvertiserPlanReport(token, getDate, getDate, CtopAdConstant.BYTEDANCE_REPORT_TYPE_DAILY);
+                if (null != token) {
+                    reportService.getAdvertiserPlanReport(token, getDate, getDate, CtopAdConstant.BYTEDANCE_REPORT_TYPE_DAILY);
+                }
             }
         }
-        formatZybData(215, getDate);
+        planDailyReportService.cleanChannelCodeData(235, getDate);
     }
 
     @Autowired

+ 1 - 10
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/batch/service/impl/KuaishouInterfaceServiceImpl.java

@@ -1039,16 +1039,8 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
             //4: 获取广告创意信息数据
             getAdvertiserCreativeReportHourly(token, getStartDate, getStartDate);
         }
-        for (int i = 0; i < 6; i++) {
             Date getStartDate = new Date();
-            Date getEndDate = new Date();
-            if (i == 0) {
-                getStartDate = DateUtils.addDay(endDate, -175 + i * 30);
-                getEndDate = DateUtils.addDay(endDate, -150 + i * 30);
-            } else {
-                getStartDate = DateUtils.addDay(endDate, -180 + i * 30);
-                getEndDate = DateUtils.addDay(endDate, -150 + i * 30);
-            }
+        Date getEndDate = DateUtils.addDay(new Date(), -6);
             //1: 获取广告主信息数据
             getAdvertiserReportDaily(token, getStartDate, getEndDate);
             //2:获取广告计划信息数据
@@ -1068,7 +1060,6 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
             getVideoList(token, null, null);
             //获取图片信息数据
             getImageList(token, null, null);
-        }
 
 
         getAppList(token.getAccountId(), token.getAccessToken());

+ 2 - 2
performance-appraisal/src/main/java/cn/com/ctop/performanceappraisal/entity/PerformanceConfig.java

@@ -29,9 +29,9 @@ public class PerformanceConfig {
     /**
      * id
      */
-    @TableId(type = IdType.UUID)
+    @TableId(type = IdType.AUTO)
     @ApiModelProperty(value = "id")
-    private Integer id;
+    private Long id;
     /**
      * year
      */