| | |
| | | package com.ycl.calculate; |
| | | |
| | | import com.ycl.platform.domain.entity.CheckIndexVideo; |
| | | import com.ycl.platform.domain.result.SYS.TMonitorResult; |
| | | import com.ycl.platform.domain.result.UY.VideoOnlineResult; |
| | | import com.ycl.platform.mapper.CheckIndexVideoMapper; |
| | | import com.ycl.platform.mapper.TMonitorMapper; |
| | |
| | | @Override |
| | | public void calculate(List<VideoOnlineResult> list) { |
| | | //获取分区域的指标数量 |
| | | Map<String, VideoOnlineCalculation.AreaStats> areaStatsMap = getAreaStatsMap(list); |
| | | Map<String, VideoOnlineCalculation.AreaStats> areaStatsMap = getAreaStatsMap(list,Boolean.TRUE); |
| | | if (areaStatsMap == null) return; |
| | | |
| | | // 查询是否index表已经存在今日数据 |
| | |
| | | BigDecimal siteOnline = siteOnline(param); |
| | | checkIndexVideo.setSiteOnline(siteOnline); |
| | | //区县不少于100路 |
| | | if(stats.totalSites < CheckThreadConstants.Check_Video_SiteOnline){ |
| | | if(!key.startsWith(ApiConstants.Dept) && stats.totalSites < CheckThreadConstants.Check_Video_SiteOnline){ |
| | | checkIndexVideo.setSiteOnline(BigDecimal.ZERO); |
| | | } |
| | | //调用点位在线率计算方法 计算重点点位在线率 |
| | |
| | | } |
| | | |
| | | //区县视频重点点位数不少于10路 |
| | | if(stats.importantSites<CheckThreadConstants.Check_Video_ImportantSite){ |
| | | if(!key.startsWith(ApiConstants.Dept) && stats.importantSites < CheckThreadConstants.Check_Video_ImportantSite){ |
| | | checkIndexVideo.setKeySiteOnline(BigDecimal.ZERO); |
| | | } |
| | | |