问题单修复
This commit is contained in:
@@ -54,6 +54,8 @@ import com.njcn.event.service.majornetwork.ReportService;
|
||||
import com.njcn.event.utils.EchartsUtil;
|
||||
import com.njcn.event.utils.FreemarkerUtil;
|
||||
import com.njcn.event.utils.WordUtils;
|
||||
import com.njcn.harmonic.pojo.vo.ComAssessVO;
|
||||
import com.njcn.influxdb.mapper.InfluxDBResultMapperCn;
|
||||
import com.njcn.influxdb.utils.InfluxDBCommUtils;
|
||||
import com.njcn.influxdb.utils.InfluxDbUtils;
|
||||
import com.njcn.poi.util.PoiUtil;
|
||||
@@ -233,7 +235,7 @@ public class ReportServiceImpl implements ReportService {
|
||||
// QueryResult queryResult = new QueryResult();
|
||||
ArrayList<GeneralVO> list = new ArrayList<>();
|
||||
for (GeneralDeviceDTO dto : data) {
|
||||
list.add(new GeneralVO(dto.getName(), 0, 0, 0, 0, 0));
|
||||
list.add(new GeneralVO(dto.getName(), 0.0,0, 0, 0, 0, 0));
|
||||
|
||||
// queryResult = null;
|
||||
// StringBuilder stringBuilder = new StringBuilder(Param.SELECT).append(Param.EVENT_DETAIL);
|
||||
@@ -305,15 +307,14 @@ public class ReportServiceImpl implements ReportService {
|
||||
}
|
||||
Map<String, String> dictMap = dictType.stream().collect(Collectors.toMap(DictData::getId, DictData::getCode));
|
||||
//查电压
|
||||
HttpResult<List<GeneralDeviceDTO>> info = generalDeviceInfoClient.getPracticalAllDeviceInfo(businessParam);
|
||||
List<GeneralDeviceDTO> data = info.getData();
|
||||
List<GeneralDeviceDTO> data = generalDeviceInfoClient.getPracticalAllDeviceInfo(businessParam).getData();
|
||||
//所有根据line_id查询出来的数据
|
||||
HashMap<String, List<EventDetail>> map = new HashMap<>();
|
||||
//循环查找所有数据
|
||||
// QueryResult queryResult = new QueryResult();
|
||||
ArrayList<GeneralVO> list = new ArrayList<>();
|
||||
for (GeneralDeviceDTO dto : data) {
|
||||
list.add(new GeneralVO(dto.getName(), 0, 0, 0, 0, 0));
|
||||
list.add(new GeneralVO(dto.getName(), 0.0,0, 0, 0, 0, 0));
|
||||
// queryResult = null;
|
||||
// StringBuilder stringBuilder = new StringBuilder(Param.SELECT + Param.EVENT_DETAIL);
|
||||
List<String> lineIndexes = dto.getLineIndexes();
|
||||
@@ -366,7 +367,9 @@ public class ReportServiceImpl implements ReportService {
|
||||
generalVO.setOffLine(dto.getLineIndexes().size() - result.getData());
|
||||
}
|
||||
}
|
||||
return list;
|
||||
list.forEach(item -> item.setVol(Double.parseDouble(item.getName().substring(0,item.getName().indexOf("k")))));
|
||||
List<GeneralVO> sortedList = list.stream().sorted(Comparator.comparing(GeneralVO::getVol)).collect(Collectors.toList());
|
||||
return sortedList;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user