|
@@ -263,8 +263,15 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Access-Token", token.getAccessToken());
|
|
headers.put("Access-Token", token.getAccessToken());
|
|
Map<String, Object> param = new HashMap<>();
|
|
Map<String, Object> param = new HashMap<>();
|
|
- param.put("start_date", DateUtils.formatDate(startDate));
|
|
|
|
- param.put("end_date", DateUtils.formatDate(endDate));
|
|
|
|
|
|
+ if (!Check.isNull(startDate)) {
|
|
|
|
+ param.put("start_date", DateUtils.formatDate(startDate));
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ if (!Check.isNull(endDate)) {
|
|
|
|
+ param.put("end_date", DateUtils.formatDate(endDate));
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+
|
|
param.put("advertiser_id", token.getAccountId());
|
|
param.put("advertiser_id", token.getAccountId());
|
|
param.put("temporal_granularity", "DAILY");
|
|
param.put("temporal_granularity", "DAILY");
|
|
param.put("page_size", 500);
|
|
param.put("page_size", 500);
|
|
@@ -350,8 +357,15 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Access-Token", token.getAccessToken());
|
|
headers.put("Access-Token", token.getAccessToken());
|
|
Map<String, Object> param = new HashMap<>();
|
|
Map<String, Object> param = new HashMap<>();
|
|
- param.put("start_date", DateUtils.formatDate(startDate));
|
|
|
|
- param.put("end_date", DateUtils.formatDate(endDate));
|
|
|
|
|
|
+
|
|
|
|
+ if (!Check.isNull(startDate)) {
|
|
|
|
+ param.put("start_date", DateUtils.formatDate(startDate));
|
|
|
|
+ }
|
|
|
|
+ if (Check.isNull(endDate)) {
|
|
|
|
+ param.put("end_date", DateUtils.formatDate(endDate));
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+
|
|
param.put("advertiser_id", token.getAccountId());
|
|
param.put("advertiser_id", token.getAccountId());
|
|
param.put("temporal_granularity", "DAILY");
|
|
param.put("temporal_granularity", "DAILY");
|
|
param.put("page_size", 500);
|
|
param.put("page_size", 500);
|
|
@@ -523,8 +537,14 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Content-Type", "application/json");
|
|
headers.put("Access-Token", token.getAccessToken());
|
|
headers.put("Access-Token", token.getAccessToken());
|
|
Map<String, Object> param = new HashMap<>();
|
|
Map<String, Object> param = new HashMap<>();
|
|
- param.put("start_date", DateUtils.formatDate(startDate));
|
|
|
|
- param.put("end_date", DateUtils.formatDate(endDate));
|
|
|
|
|
|
+ if (!Check.isNull(startDate)) {
|
|
|
|
+ param.put("start_date", DateUtils.formatDate(startDate));
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ if (!Check.isNull(endDate)) {
|
|
|
|
+ param.put("end_date", DateUtils.formatDate(endDate));
|
|
|
|
+ }
|
|
|
|
+
|
|
param.put("advertiser_id", token.getAccountId());
|
|
param.put("advertiser_id", token.getAccountId());
|
|
param.put("temporal_granularity", "DAILY");
|
|
param.put("temporal_granularity", "DAILY");
|
|
param.put("page_size", 500);
|
|
param.put("page_size", 500);
|