1.数据完整性列表筛选条件调整
2.管理员新增装置自动生成装置名称
This commit is contained in:
@@ -70,4 +70,6 @@ public interface DeviceMapper extends Mapper<Device>{
|
||||
List<Integer> getDevIndex(@Param("list") List<Integer> dataType);
|
||||
|
||||
DeviceDetail getDevAndParent(@Param("devIndex")String devIndex);
|
||||
|
||||
String findMaxDeviceName(@Param("gdIndex")Long gdIndex);
|
||||
}
|
||||
|
||||
@@ -53,6 +53,8 @@ public interface LineMapper extends Mapper<Line> {
|
||||
//根据现有的监测点筛选出国网监测点
|
||||
List<Integer> getGWLines(@Param("list") List<Integer> subList);
|
||||
|
||||
List<Integer> getAllGWLines(@Param("list") List<Integer> subList);
|
||||
|
||||
String selectLineName(String name);
|
||||
|
||||
//获取该表所有数据,提供excel导出
|
||||
|
||||
@@ -340,7 +340,7 @@ public class DeviceServiceImpl implements DeviceService {
|
||||
}
|
||||
intergralityData.setAllNets(list1);
|
||||
//国网监测点
|
||||
List<Integer> countryLineIndexs = getGwLine(lineIndexs);
|
||||
List<Integer> countryLineIndexs = getAllGwLine(lineIndexs);
|
||||
if (!CollectionUtils.isEmpty(countryLineIndexs)) {
|
||||
List<IntergralityTable> list2 = getGWIntegralityTable(startTime, endTime, countryLineIndexs);
|
||||
if (CollUtil.isNotEmpty(list2)){
|
||||
@@ -1085,6 +1085,30 @@ public class DeviceServiceImpl implements DeviceService {
|
||||
return tempLine;
|
||||
}
|
||||
|
||||
private List<Integer> getAllGwLine(List<Integer> lines) {
|
||||
if (CollectionUtils.isEmpty(lines)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<Integer> lineTemp = new ArrayList<>(lines);
|
||||
List<Integer> tempLine = new ArrayList<>();
|
||||
if (lineTemp.size() > 1000) {
|
||||
int times = lineTemp.size() / 1000 + 1;
|
||||
for (int i = 0; i < times; i++) {
|
||||
if (lineTemp.size() > 1000) {
|
||||
List<Integer> subList = lineTemp.subList(0, 1000);
|
||||
List<Integer> temp = lineMapper.getAllGWLines(subList);
|
||||
subList.clear();
|
||||
tempLine.addAll(temp);
|
||||
} else {
|
||||
tempLine.addAll(lineMapper.getAllGWLines(lineTemp));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
tempLine.addAll(lineMapper.getAllGWLines(lineTemp));
|
||||
}
|
||||
return tempLine;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据监测点索引获取当前的数据完整性
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user