Commit 7c597757 authored by 赵啸非's avatar 赵啸非

添加设备上线和下线的业务日志记录

parent c79401b3
...@@ -230,14 +230,13 @@ public class SitestatServiceImpl extends AbstractCRUDServiceImpl<SitestatDao, Si ...@@ -230,14 +230,13 @@ public class SitestatServiceImpl extends AbstractCRUDServiceImpl<SitestatDao, Si
Map<String, Object> model = new HashMap<>(); Map<String, Object> model = new HashMap<>();
if (!ObjectUtils.isEmpty(token)) { if (!ObjectUtils.isEmpty(token)) {
String resp = siteFeign.siteTree(token); String resp = siteFeign.siteTree(token);
Rest<Rest<String>> rest = JSON.parseObject(resp, new TypeReference<Rest<Rest<String>>>() { Rest<String> rest = JSON.parseObject(resp, new TypeReference<Rest<String>>() {
}); });
if(rest.getCode()==YesNoEnum.YES.getValue()){ if(rest.getCode()==YesNoEnum.YES.getValue()){
String siteTreeSelectStr = rest.getData().getData(); String siteTreeSelectStr = rest.getData();
// Rest<String> restSite = JSON.parseObject(siteTreeSelectStr, new TypeReference<Rest<String>>() { JSONObject json = JSON.parseObject(siteTreeSelectStr);
// }); JSONArray jsonArray = json.getJSONArray("siteTree");
JSONArray jsonArray = JSON.parseArray(siteTreeSelectStr);
if (ObjectUtils.isEmpty(jsonArray)) { if (ObjectUtils.isEmpty(jsonArray)) {
jsonObject.put(KEY_RESULT_DATA, new JSONArray()); jsonObject.put(KEY_RESULT_DATA, new JSONArray());
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS); jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
......
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