Commit a2330c34 authored by linruibiao's avatar linruibiao

接口编写

parent bb674e81
......@@ -130,11 +130,7 @@ public class BusinessConfigServiceImpl extends ServiceImpl<BusinessConfigMapper,
uriVariables.put("size", size);
uriVariables.put("name", name);
IPage<String> page = new Page<>(current,size);
R<Map<String,Object>> result = RestTemplateUtils.get(uri,()->{
Map<String, String> header = Maps.newHashMap();
header.put("X-Token", currentUser.getToken());
return header;
}, new TypeToken<R<Map<String,Object>>>() {}.getType(), uriVariables);
R<Map<String,Object>> result = RestTemplateUtils.get(uri, new TypeToken<R<Map<String,Object>>>() {}.getType(), uriVariables);
Map<String, Object> resultMaps = result.detach();
if(CollectionUtils.isNotEmpty(resultMaps)){
page.setTotal(new BigDecimal(resultMaps.get("total")+"").longValue());
......
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