Selaa lähdekoodia

adq定时任务

yumeng 1 viikko sitten
vanhempi
commit
eeef8bd01b

+ 1 - 1
job-adq/src/main/java/cn/com/ctop/job/adq/controller/AdqController.java

@@ -46,7 +46,7 @@ public class AdqController {
         String nowDate = DateUtils.getNowDate("yyyy-MM-dd");
         String nowDate = DateUtils.getNowDate("yyyy-MM-dd");
        /* accountReportService.getAdqAccountHour(advertiserId, accessToken, nowDate, nowDate, 1, 1);
        /* accountReportService.getAdqAccountHour(advertiserId, accessToken, nowDate, nowDate, 1, 1);
         accountReportService.getAdqAccountDaily(advertiserId, accessToken, nowDate, nowDate, 1, 1);*/
         accountReportService.getAdqAccountDaily(advertiserId, accessToken, nowDate, nowDate, 1, 1);*/
-        adqMaterialReportService.getAdqMaterialDailyReport(advertiserId, accessToken, "2026-06-03", "2026-06-03", 1, 1, null, 0);
+        adqMaterialReportService.getAdqMaterialDailyReport(advertiserId, accessToken, "2026-06-14", "2026-06-14", 1, 1, null, 0);
         // adqMediaInfoService.getVideoListIncrement(advertiserId, accessToken);
         // adqMediaInfoService.getVideoListIncrement(advertiserId, accessToken);
 
 
    /*     adqMediaInfoService.getVideoListAll(advertiserId, accessToken);
    /*     adqMediaInfoService.getVideoListAll(advertiserId, accessToken);

+ 1 - 1
job-adq/src/main/java/cn/com/ctop/job/adq/data/service/impl/AdqAccountReportServiceImpl.java

@@ -148,7 +148,7 @@ public class AdqAccountReportServiceImpl implements IAdqAccountReportService {
                 accountReportMapper.addAccountDailyList(dailyList);
                 accountReportMapper.addAccountDailyList(dailyList);
             }
             }
             if (dailyList.size() >= 1000) {
             if (dailyList.size() >= 1000) {
-                getAdqAccountHour(advertiserId, accessToken, startDate, endDate, page + 1, isLog);
+                getAdqAccountDaily(advertiserId, accessToken, startDate, endDate, page + 1, isLog);
             } else {
             } else {
                 log.info("请求账户日报完成,account_id:{},开始日期:{},开始日期:{}", advertiserId, startDate, endDate);
                 log.info("请求账户日报完成,account_id:{},开始日期:{},开始日期:{}", advertiserId, startDate, endDate);
                 JSONObject param = new JSONObject();
                 JSONObject param = new JSONObject();

+ 2 - 1
job-adq/src/main/java/cn/com/ctop/job/adq/data/service/impl/AdqMaterialReportServiceImpl.java

@@ -56,7 +56,7 @@ public class AdqMaterialReportServiceImpl implements IAdqMaterialReportService {
             date_range.put("start_date", startDate);
             date_range.put("start_date", startDate);
             date_range.put("end_date", endDate);
             date_range.put("end_date", endDate);
             paramsMap.put("date_range", date_range);
             paramsMap.put("date_range", date_range);
-         //   paramsMap.put("time_line", "REPORTING_TIME");
+            paramsMap.put("time_line", "REPORTING_TIME");
             JSONArray group_by = new JSONArray();
             JSONArray group_by = new JSONArray();
             group_by.add("date");
             group_by.add("date");
             JSONArray fieldsList = FieldsConfig.getMaterialDailyFieldsList();
             JSONArray fieldsList = FieldsConfig.getMaterialDailyFieldsList();
@@ -71,6 +71,7 @@ public class AdqMaterialReportServiceImpl implements IAdqMaterialReportService {
             paramsMap.put("fields", fieldsList);
             paramsMap.put("fields", fieldsList);
             String s = HttpUtils.httpGet("https://api.e.qq.com/v3.0/daily_reports/get", paramsMap, null);
             String s = HttpUtils.httpGet("https://api.e.qq.com/v3.0/daily_reports/get", paramsMap, null);
             JSONObject jsonObject = JSONObject.parseObject(s);
             JSONObject jsonObject = JSONObject.parseObject(s);
+            System.err.println(jsonObject);
             int totalPage = 1;
             int totalPage = 1;
             List<AdqMaterialReportDaily> reportList = new ArrayList<>();
             List<AdqMaterialReportDaily> reportList = new ArrayList<>();
             if (Check.isNull(jsonObject)) {
             if (Check.isNull(jsonObject)) {