Commit 70f8f6ee authored by 赵啸非's avatar 赵啸非

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

parent 7c597757
package com.mortals.xhx.base.framework.config; package com.mortals.xhx.base.framework.config;
import com.alibaba.fastjson.parser.ParserConfig;
import com.mortals.xhx.module.site.model.SiteTreeSelect;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
import org.springframework.web.cors.CorsConfiguration; import org.springframework.web.cors.CorsConfiguration;
...@@ -18,6 +20,8 @@ public class CorsConfig implements WebMvcConfigurer { ...@@ -18,6 +20,8 @@ public class CorsConfig implements WebMvcConfigurer {
@Bean @Bean
public CorsFilter corsFilter(){ public CorsFilter corsFilter(){
ParserConfig.getGlobalInstance().putDeserializer(SiteTreeSelect.class, new SiteTreeSelect.Deserializer());
//初始化配置对象 //初始化配置对象
CorsConfiguration configuration = new CorsConfiguration(); CorsConfiguration configuration = new CorsConfiguration();
//允许跨域访问的域名 //允许跨域访问的域名
......
...@@ -212,7 +212,6 @@ public class SiteTreeSelect implements Serializable { ...@@ -212,7 +212,6 @@ public class SiteTreeSelect implements Serializable {
.count(); .count();
node.setOfflineTotal(deviceOfflineCount.intValue()); node.setOfflineTotal(deviceOfflineCount.intValue());
} }
//todo 统计当前区域下的所有站点数量
sitePdu.setAreaCode(node.getAreaCode()); sitePdu.setAreaCode(node.getAreaCode());
Rest<Integer> rest = siteFeign.countSitesByArea(sitePdu); Rest<Integer> rest = siteFeign.countSitesByArea(sitePdu);
......
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