Commit 4eee1986 by guojx

数据接口超过90天调整名称

parent 114b3bfb
......@@ -10,6 +10,7 @@ import com.gic.commons.util.DataApiUtils;
import com.gic.commons.util.EntityUtil;
import com.gic.commons.util.GlobalVar;
import com.gic.commons.util.HttpClient;
import com.gic.commons.util.data.CrossDateUtils;
import com.gic.commons.webapi.reponse.RestResponse;
import com.gic.enterprise.api.dto.EnterpriseSettingDTO;
import com.gic.enterprise.api.dto.EnterpriseSourceChannelDTO;
......@@ -155,10 +156,14 @@ public class DataController {
jsonObject.put("storeId", storeIdList.stream().collect(Collectors.joining(",")));
}
}
Map<String, Object> res = DataApiUtils.http(jsonObject.toJSONString(), qo.getApolloKey());
String apolloKey = qo.getApolloKey();
boolean isNeedFill = (apolloKey.contains("custom")
String useApolloKey = CrossDateUtils.getUseApolloKey(jsonObject == null ? null : jsonObject.getString("startDate"), apolloKey);
Map<String, Object> res = DataApiUtils.http(jsonObject.toJSONString(), useApolloKey);
boolean isNeedFill = (apolloKey.contains("data_mbr_scale_stat_new_custm_overview")
|| apolloKey.contains("data_sales_perf_anal_cont_custm_overview")
|| apolloKey.contains("month") || apolloKey.contains("day") ||
apolloKey.contains("week"))
&& jsonObject.containsKey("storeGroup") &&
......@@ -178,7 +183,7 @@ public class DataController {
dateTypeList = DateFillUtils.getMonth(jsonObject.getString("startDate").substring(0, 7));
} else if (apolloKey.contains("week")) {
dateTypeList = DateFillUtils.getWeek(jsonObject.getString("startDate"));
} else if (apolloKey.contains("custom")) {
} else if (apolloKey.contains("custm")) {
dateTypeList = DateFillUtils.getCustom(jsonObject.getString("startDate"), jsonObject.getString("endDate"));
}
if (CollectionUtils.isNotEmpty(dateTypeList)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment