市局数据资源对接修改

This commit is contained in:
dinggang 2022-06-24 19:10:51 +08:00
parent c5f8697a43
commit bf5628d97f
1 changed files with 2 additions and 5 deletions

View File

@ -409,10 +409,9 @@ public class CensusControllerV2 {
TsingtaoDataResourceService tsingtaoDataResourceService = new TsingtaoDataResourceService();
GetDataResourceListDto getDataResourceListDto = new GetDataResourceListDto().setPageNum(1).setPageSize(5);
HashMap dataResource = (HashMap) tsingtaoDataResourceService.getDataResource(getDataResourceListDto);
JSONObject data = JSON.parseObject(JSON.toJSONString(dataResource.get("data")));
result.add(new HashMap<String, Object>() {
{
put("amount", data.get("rows"));
put("amount", dataResource.get("rows"));
put("type", "总数据量");
}
});
@ -430,8 +429,7 @@ public class CensusControllerV2 {
});
result.add(new HashMap<String, Object>() {
{
String ja = data.getString("data");
List<Map> lists = JSON.parseArray(ja, Map.class);
List<Map> lists = (List<Map>) dataResource.get("data");
ArrayList<Map> list = new ArrayList<>();
lists.forEach(item -> {
list.add(new HashMap<String, Object>() {{
@ -468,7 +466,6 @@ public class CensusControllerV2 {
logger.error("青岛西海岸失败", exception);
}
OkHttpClient client1 = new OkHttpClient();
Request request1 = new Request.Builder().url(tsingtao_xhaProperties.getResourceapplyinfo()).build();
try (Response response = client1.newCall(request1).execute()) {