Commit b77e7fbd authored by hezhuozhi's avatar hezhuozhi

大屏升压站数据

parent 18f578ef
......@@ -436,9 +436,9 @@ public class BigScreenAnalyseController extends BaseController {
@GetMapping("/getFanInfoByPage")
public ResponseModel<Page<Map<String, Object>>> getFanInfoByPage(@RequestParam(value = "stationId", required = false) String stationId) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getFanInfoByPage(stationBasic.getFanGatewayId());
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getFanInfoByPage(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
List<Map<String, Object>> healthInfoList = idxBizFanHealthIndexMapper.getFanHealthInfoList(stationBasic.getFanGatewayId());
List<Map<String, Object>> healthInfoList = idxBizFanHealthIndexMapper.getFanHealthInfoList(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Double> equipmentHealthIndexMap = healthInfoList.stream().collect(Collectors.toMap(t -> t.get("equipmentName"), t -> Double.parseDouble(t.get("avgHealthIndex").toString())));
equipmentList.forEach(item -> {
......@@ -488,13 +488,13 @@ public class BigScreenAnalyseController extends BaseController {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
Map<String, Object> resultMap = new HashMap<>();
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getSubSystemInfo(equipmentName, stationBasic.getFanGatewayId());
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getSubSystemInfo(equipmentName, stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Integer> equipmentHealthIndexMap = healthListInfo.stream().collect(Collectors.toMap(t -> t.get("subSystem"), t -> Integer.valueOf(t.get("healthIndex").toString().replace(".0", ""))));
List<Object> seriesData = new ArrayList<>();
List<Object> axisData = new ArrayList<>();
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getSumSystemListByEquipment(stationBasic.getFanGatewayId(), equipmentName);
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getSumSystemListByEquipment(stationBasic.getFanGatewayId(), equipmentName,stationBasic.getBoosterGatewayId());
equipmentList.forEach(item -> {
Integer equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("subSystem"), 100);
seriesData.add(equipmentHealthScore);
......@@ -524,7 +524,7 @@ private FanHealthIndexMapper fanHealthIndexMapper;
Map<Object, String> equipmentHealthIndexMap = healthListInfo.stream()
.collect(Collectors.toMap(t -> t.get("pointname"), t -> t.get("warningname").toString()));
List<Map<String, Object>> pointNameList = idxBizFanHealthIndexMapper
.getPointNameListBySumSystem(stationBasic.getFanGatewayId(), subSystem, equipmentName);
.getPointNameListBySumSystem(stationBasic.getFanGatewayId(), subSystem, equipmentName,stationBasic.getBoosterGatewayId());
pointNameList.forEach(item -> {
String warningName = equipmentHealthIndexMap.getOrDefault(item.get("pointName"), "安全");
int sort = 4;
......@@ -557,9 +557,9 @@ private FanHealthIndexMapper fanHealthIndexMapper;
@GetMapping("/getPvInfoByPage")
public ResponseModel<Page<Map<String, Object>>> getPvInfoByPage(@RequestParam(value = "stationId", required = false) String stationId) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getPvInfoByPage(stationBasic.getFanGatewayId());
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getPvInfoByPage(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
List<Map<String, Object>> healthInfoList = idxBizFanHealthIndexMapper.getPvHealthInfoList(stationBasic.getFanGatewayId());
List<Map<String, Object>> healthInfoList = idxBizFanHealthIndexMapper.getPvHealthInfoList(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Double> equipmentHealthIndexMap = healthInfoList.stream().collect(Collectors.toMap(t -> t.get("subarray"), t -> Double.parseDouble(t.get("avgHealthIndex").toString())));
equipmentList.forEach(item -> {
......@@ -599,13 +599,13 @@ private FanHealthIndexMapper fanHealthIndexMapper;
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
Map<String, Object> resultMap = new HashMap<>();
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getPvSubSystemInfo(subarray, stationBasic.getFanGatewayId());
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getPvSubSystemInfo(subarray, stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Object> equipmentHealthIndexMap = healthListInfo.stream().collect(Collectors.toMap(t -> t.get("equipmentName"), t -> t.get("avgHealthIndex").toString().replace(".0", "")));
List<Object> seriesData = new ArrayList<>();
List<Object> axisData = new ArrayList<>();
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getPvSumSystemListByEquipment(stationBasic.getFanGatewayId(), subarray);
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper.getPvSumSystemListByEquipment(stationBasic.getFanGatewayId(), subarray,stationBasic.getBoosterGatewayId());
equipmentList.forEach(item -> {
Object equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("equipmentName"), 100);
seriesData.add(equipmentHealthScore);
......@@ -623,11 +623,11 @@ private FanHealthIndexMapper fanHealthIndexMapper;
@RequestParam(value = "stationId", required = false) String stationId) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getPvHealthInfoBySubSystem(equipmentName, stationBasic.getFanGatewayId());
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getPvHealthInfoBySubSystem(equipmentName, stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Double> equipmentHealthIndexMap = healthListInfo.stream().collect(Collectors.toMap(t -> t.get("pointName"), t -> Double.parseDouble(t.get("healthIndex").toString())));
List<Map<String, Object>> pointNameList = idxBizFanHealthIndexMapper.getPvPointNameListBySumSystem(stationBasic.getFanGatewayId(), equipmentName);
List<Map<String, Object>> pointNameList = idxBizFanHealthIndexMapper.getPvPointNameListBySumSystem(stationBasic.getFanGatewayId(), equipmentName,stationBasic.getBoosterGatewayId());
pointNameList.forEach(item -> {
Double equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("pointName"), 100.0);
......@@ -724,9 +724,9 @@ private FanHealthIndexDayMapper fanHealthIndexDayMapper;
@RequestParam(value = "stationId", required = true) String stationId,
@RequestParam(value = "tableName2", required = false) String tableName2) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
String nameByIndexAddress = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(indexAddress, tableName, stationBasic.getFanGatewayId());
String nameByIndexAddress = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(indexAddress, tableName, stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
int num = idxBizFanHealthIndexMapper.getIsWarningByPointId(indexAddress, stationBasic.getFanGatewayId(), tableName2);
int num = idxBizFanHealthIndexMapper.getIsWarningByPointId(indexAddress, stationBasic.getFanGatewayId(), tableName2,stationBasic.getBoosterGatewayId());
HashMap<String, Object> resultMap = new HashMap<>();
resultMap.put("text", nameByIndexAddress);
......@@ -742,7 +742,7 @@ private FanHealthIndexDayMapper fanHealthIndexDayMapper;
@RequestParam(value = "stationId") String stationId) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
varDesc = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(varDesc, tableName, stationBasic.getFanGatewayId());
varDesc = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(varDesc, tableName, stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
FeignClientResult<List<String>> sevenEntityMcb = null;
try {
sevenEntityMcb = riskWarningFeign.getRiskHandleByVarDesc(varDesc);
......
......@@ -768,10 +768,10 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
private Page<Map<String, Object>> fanInfoByPage(String stationId) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper
.getFanInfoByPage(stationBasic.getFanGatewayId());
.getFanInfoByPage(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
List<Map<String, Object>> healthInfoList = idxBizFanHealthIndexMapper
.getFanHealthInfoList(stationBasic.getFanGatewayId());
.getFanHealthInfoList(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Double> equipmentHealthIndexMap = healthInfoList.stream().collect(Collectors
.toMap(t -> t.get("equipmentName"), t -> Double.parseDouble(t.get("avgHealthIndex").toString())));
......@@ -824,7 +824,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
Map<String, Object> resultMap = new HashMap<>();
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getSubSystemInfo(equipmentName,
stationBasic.getFanGatewayId());
stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Object> equipmentHealthIndexMap = healthListInfo.stream()
.collect(Collectors.toMap(t -> t.get("subSystem"), t -> t.get("healthIndex")));
......@@ -832,7 +832,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
List<Object> axisData = new ArrayList<>();
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper
.getSumSystemListByEquipment(stationBasic.getFanGatewayId(), equipmentName);
.getSumSystemListByEquipment(stationBasic.getFanGatewayId(), equipmentName,stationBasic.getBoosterGatewayId());
equipmentList.forEach(item -> {
Object equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("subSystem"), 100.0);
seriesData.add(equipmentHealthScore);
......@@ -857,13 +857,13 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
equipmentName = StrUtil.isNotEmpty(equipmentName) ? "%" + equipmentName + "风机%" : equipmentName;
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getHealthInfoBySubSystem(subSystem,
stationBasic.getFanGatewayId(), equipmentName);
stationBasic.getFanGatewayId(), equipmentName,stationBasic.getBoosterGatewayId());
Map<Object, Double> equipmentHealthIndexMap = healthListInfo.stream().collect(
Collectors.toMap(t -> t.get("pointName"), t -> Double.parseDouble(t.get("healthIndex").toString())));
List<Map<String, Object>> pointNameList = idxBizFanHealthIndexMapper
.getPointNameListBySumSystem(stationBasic.getFanGatewayId(), subSystem, equipmentName);
.getPointNameListBySumSystem(stationBasic.getFanGatewayId(), subSystem, equipmentName,stationBasic.getBoosterGatewayId());
pointNameList.forEach(item -> {
Double equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("pointName"), 100.0);
......@@ -920,10 +920,10 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper
.getPvInfoByPage(stationBasic.getFanGatewayId());
.getPvInfoByPage(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
List<Map<String, Object>> healthInfoList = idxBizFanHealthIndexMapper
.getPvHealthInfoList(stationBasic.getFanGatewayId());
.getPvHealthInfoList(stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Double> equipmentHealthIndexMap = healthInfoList.stream().collect(
Collectors.toMap(t -> t.get("subarray"), t -> Double.parseDouble(t.get("avgHealthIndex").toString())));
......@@ -967,7 +967,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
Map<String, Object> resultMap = new HashMap<>();
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getPvSubSystemInfo(subarray,
stationBasic.getFanGatewayId());
stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Object> equipmentHealthIndexMap = healthListInfo.stream()
.collect(Collectors.toMap(t -> t.get("equipmentName"), t -> t.get("avgHealthIndex")));
......@@ -975,7 +975,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
List<Object> axisData = new ArrayList<>();
List<Map<String, Object>> equipmentList = idxBizFanHealthIndexMapper
.getPvSumSystemListByEquipment(stationBasic.getFanGatewayId(), subarray);
.getPvSumSystemListByEquipment(stationBasic.getFanGatewayId(), subarray,stationBasic.getBoosterGatewayId());
equipmentList.forEach(item -> {
Object equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("equipmentName"), 100.0);
seriesData.add(equipmentHealthScore);
......@@ -998,13 +998,13 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
private Page<Map<String, Object>> pvSubSystemPointInfo(String equipmentName,String stationId) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
List<Map<String, Object>> healthListInfo = idxBizFanHealthIndexMapper.getPvHealthInfoBySubSystem(equipmentName,
stationBasic.getFanGatewayId());
stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
Map<Object, Double> equipmentHealthIndexMap = healthListInfo.stream().collect(
Collectors.toMap(t -> t.get("pointName"), t -> Double.parseDouble(t.get("healthIndex").toString())));
List<Map<String, Object>> pointNameList = idxBizFanHealthIndexMapper
.getPvPointNameListBySumSystem(stationBasic.getFanGatewayId(), equipmentName);
.getPvPointNameListBySumSystem(stationBasic.getFanGatewayId(), equipmentName,stationBasic.getBoosterGatewayId());
pointNameList.forEach(item -> {
Double equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("pointName"), 100.0);
......@@ -1101,11 +1101,11 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
@RequestParam(value = "tableName2", required = false) String tableName2) {
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
String nameByIndexAddress = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(indexAddress, tableName,
stationBasic.getFanGatewayId());
stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
int num = 0;
if (StringUtils.isNotEmpty(tableName2)) {
num = idxBizFanHealthIndexMapper.getIsWarningByPointId(indexAddress, stationBasic.getFanGatewayId(),
tableName2);
tableName2,stationBasic.getBoosterGatewayId());
}
HashMap<String, Object> resultMap = new HashMap<>();
......@@ -1124,7 +1124,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
varDesc = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(varDesc, tableName,
stationBasic.getFanGatewayId());
stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
FeignClientResult<List<String>> sevenEntityMcb = null;
try {
sevenEntityMcb = riskWarningFeign.getRiskHandleByVarDesc(varDesc);
......@@ -1714,7 +1714,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
Map<String, Object> healthIndexMap = idxBizFanHealthIndexMapper
.getHealthIndexByIndexAddress(stationBasic.getFanGatewayId(), varDesc);
.getHealthIndexByIndexAddress(stationBasic.getFanGatewayId(), varDesc,stationBasic.getBoosterGatewayId());
if (ObjectUtils.isEmpty(healthIndexMap)) {
HashMap<String, String> stringStringHashMap = new HashMap<>();
stringStringHashMap.put("content", "正常运行");
......@@ -1733,7 +1733,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
}
varDesc = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(varDesc, tableName,
stationBasic.getFanGatewayId());
stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
FeignClientResult<List<String>> sevenEntityMcb = null;
try {
sevenEntityMcb = riskWarningFeign.getRiskHandleByVarDesc(varDesc);
......@@ -1765,7 +1765,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
StationBasic stationBasic = stationBasicMapper.selectById(stationId);
Map<String, Object> healthIndexMap = idxBizFanHealthIndexMapper
.getHealthIndexByIndexAddressPv(stationBasic.getFanGatewayId(), varDesc);
.getHealthIndexByIndexAddressPv(stationBasic.getFanGatewayId(), varDesc,stationBasic.getBoosterGatewayId());
if (ObjectUtils.isEmpty(healthIndexMap)) {
HashMap<String, String> stringStringHashMap = new HashMap<>();
stringStringHashMap.put("content", "正常运行");
......@@ -1784,7 +1784,7 @@ public class TDBigScreenAnalyseController extends BaseController implements Appl
}
varDesc = idxBizFanHealthIndexMapper.getPointNameByIndexAddress(varDesc, tableName,
stationBasic.getFanGatewayId());
stationBasic.getFanGatewayId(),stationBasic.getBoosterGatewayId());
FeignClientResult<List<String>> sevenEntityMcb = null;
try {
sevenEntityMcb = riskWarningFeign.getRiskHandleByVarDesc(varDesc);
......
......@@ -59,47 +59,49 @@ public interface IdxBizFanHealthIndexMapper extends BaseMapper<IdxBizFanHealthIn
List<Map<String, Object>> getAllEquipAlarmInfoAnalysisByArea(@Param("areaCode") String areaCode);
List<Map<String, Object>> getSubSystemInfo(@Param("equipmentName") String equipmentName,
@Param("gatewayId") String gatewayId);
@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getFanInfoByPage(@Param("gatewayId") String gatewayId);
List<Map<String, Object>> getFanInfoByPage(@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getFanHealthInfoList(@Param("gatewayId") String gatewayId);
List<Map<String, Object>> getFanHealthInfoList(@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getSumSystemListByEquipment(@Param("gatewayId") String gatewayId,
@Param("equipmentName") String equipmentName);
@Param("equipmentName") String equipmentName,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPointNameListBySumSystem(@Param("gatewayId") String gatewayId,
@Param("subSystem") String subSystem,
@Param("equipmentName") String equipmentName);
@Param("equipmentName") String equipmentName,
@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getHealthInfoBySubSystem(@Param("subSystem") String subSystem,
@Param("gatewayId") String gatewayId,
@Param("equipmentName") String equipmentName);
@Param("equipmentName") String equipmentName,
@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getWarningInfoBySubSystem(@Param("subSystem") String subSystem,
@Param("gatewayId") String gatewayId);
@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPvInfoByPage(@Param("gatewayId") String gatewayId);
List<Map<String, Object>> getPvInfoByPage(@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPvHealthInfoList(@Param("gatewayId") String gatewayId);
List<Map<String, Object>> getPvHealthInfoList(@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPvSubSystemInfo(@Param("subarray") String subarray,
@Param("gatewayId") String gatewayId);
@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPvSumSystemListByEquipment(@Param("gatewayId") String gatewayId,
@Param("subarray") String subarray);
@Param("subarray") String subarray,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPvHealthInfoBySubSystem(@Param("equipmentName") String equipmentName,
@Param("gatewayId") String gatewayId);
@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPvWarningInfoBySubSystem(@Param("equipmentName") String equipmentName,
@Param("gatewayId") String gatewayId);
@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getPvPointNameListBySumSystem(@Param("gatewayId") String gatewayId,
@Param("equipmentName") String equipmentName);
@Param("equipmentName") String equipmentName,@Param("syzGatewayId") String syzGatewayId);
String getPointNameByIndexAddress(@Param("varDesc") String varDesc, @Param("tableName") String tableName,
@Param("gatewayId") String gatewayId);
@Param("gatewayId") String gatewayId,@Param("syzGatewayId") String syzGatewayId);
List<FullViewRecallDataDTO> getFullViewRecall(@Param("gatewayIds") List<String> gatewayIds);
......@@ -150,19 +152,19 @@ public interface IdxBizFanHealthIndexMapper extends BaseMapper<IdxBizFanHealthIn
Map<String, Object> getPvEquipStatusByStation(String station);
String getRecDateByIndexAddress(@Param("fanGatewayId") String fanGatewayId,
@Param("indexAddress") String indexAddress, @Param("tableName") String tableName);
@Param("indexAddress") String indexAddress, @Param("tableName") String tableName,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> getInfoListByTableName(@Param("fanGatewayId") String fanGatewayId,
@Param("indexAddress") String indexAddress, @Param("tableName") String tableName,
@Param("recDate") String recDate);
@Param("recDate") String recDate,@Param("syzGatewayId") String syzGatewayId);
int getIsWarningByPointId(@Param("indexAddress") String indexAddress, @Param("fanGatewayId") String fanGatewayId,
@Param("tableName") String tableName);
@Param("tableName") String tableName,@Param("syzGatewayId") String syzGatewayId);
List<Map<String, Object>> queryIndexByArae(String ARAE, String ANALYSISTYPE, String startTimeTop,
String endTimeTop);
Map<String, Object> getHealthIndexByIndexAddress(@Param("gatewayId") String gatewayId, @Param("indexAddress") String indexAddress);
Map<String, Object> getHealthIndexByIndexAddress(@Param("gatewayId") String gatewayId, @Param("indexAddress") String indexAddress,@Param("syzGatewayId") String syzGatewayId);
Map<String, Object> getHealthIndexByIndexAddressPv(@Param("gatewayId") String gatewayId, @Param("indexAddress") String indexAddress);
Map<String, Object> getHealthIndexByIndexAddressPv(@Param("gatewayId") String gatewayId, @Param("indexAddress") String indexAddress,@Param("syzGatewayId") String syzGatewayId);
}
......@@ -493,10 +493,10 @@ FROM (
<!--AND DATE_FORMAT( REC_DATE, '%Y-%m-%d' ) = CURRENT_DATE - INTERVAL 1 DAY-->
<!--AND DATE_FORMAT( REC_DATE, '%Y-%m-%d' ) = get_time_sub(1,'DAY')-->
<if test="equipmentName != null and equipmentName != ''">
AND EQUIPMENT_NAME like concat( '%', #{equipmentName} ,'风机')
AND (EQUIPMENT_NAME like concat( '%', #{equipmentName} ,'风机') or EQUIPMENT_NAME = #{equipmentName})
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
group by subSystem
......@@ -511,7 +511,7 @@ FROM (
<where>
EQUIPMENT_NAME LIKE '%#%'
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -530,7 +530,7 @@ FROM (
AND ANALYSIS_TYPE = '按10分钟'
<!--AND DATE_FORMAT( REC_DATE, '%Y-%m-%d' ) = CURRENT_DATE - INTERVAL 1 DAY-->
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -546,10 +546,10 @@ FROM (
SUB_SYSTEM IS NOT NULL AND SUB_SYSTEM != ''
AND TAG_CODE = '分析变量'
<if test="equipmentName != null and equipmentName != ''">
AND EQUIPMENT_NAME like concat( '%', #{equipmentName} ,'风机')
AND (EQUIPMENT_NAME like concat( '%', #{equipmentName} ,'风机') or EQUIPMENT_NAME = #{equipmentName})
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -568,7 +568,7 @@ FROM (
AND SUB_SYSTEM = #{subSystem}
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
<if test="equipmentName != null and equipmentName != ''">
AND EQUIPMENT_NAME like #{equipmentName}
......@@ -592,7 +592,7 @@ FROM (
AND SUB_SYSTEM = #{subSystem}
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
<if test="equipmentName != null and equipmentName != ''">
AND EQUIPMENT_NAME like #{equipmentName}
......@@ -613,7 +613,7 @@ FROM (
AND SUB_SYSTEM = #{subSystem}
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -629,7 +629,7 @@ FROM (
idx_biz_pv_point_process_variable_classification
<where>
<if test="gatewayId != null and gatewayId != ''">
GATEWAY_ID = #{gatewayId}
GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId}
</if>
</where>
GROUP BY
......@@ -648,7 +648,7 @@ FROM (
AND ANALYSIS_TYPE = '按10分钟'
<!--AND DATE_FORMAT( REC_DATE, '%Y-%m-%d' ) = CURRENT_DATE - INTERVAL 1 DAY-->
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY SUBARRAY
......@@ -666,10 +666,10 @@ FROM (
<!--AND DATE_FORMAT( REC_DATE, '%Y-%m-%d' ) = CURRENT_DATE - INTERVAL 1 DAY-->
<!--AND DATE_FORMAT( REC_DATE, '%Y-%m-%d' ) = get_time_sub(1,'DAY')-->
<if test="subarray != null and subarray != ''">
AND SUBARRAY = concat('#', #{subarray})
AND (SUBARRAY = concat('#', #{subarray}) or SUBARRAY=#{subarray})
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
group by EQUIPMENT_NAME
......@@ -684,10 +684,10 @@ FROM (
AND EQUIPMENT_NAME != ''
AND TAG_CODE = '分析变量'
<if test="subarray != null and subarray != ''">
AND SUBARRAY = concat('#', #{subarray})
AND (SUBARRAY = concat('#', #{subarray}) or SUBARRAY=#{subarray})
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -708,7 +708,7 @@ FROM (
AND EQUIPMENT_NAME = #{equipmentName}
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -726,7 +726,7 @@ FROM (
AND EQUIPMENT_NAME = #{equipmentName}
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -747,7 +747,7 @@ FROM (
AND EQUIPMENT_NAME = #{equipmentName}
</if>
<if test="gatewayId != null and gatewayId != ''">
AND GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
</if>
</where>
GROUP BY
......@@ -757,7 +757,7 @@ FROM (
select POINT_NAME
from ${tableName}
where INDEX_ADDRESS = #{varDesc}
and GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
limit 1
......@@ -1354,7 +1354,7 @@ FROM (
WHERE
INDEX_ADDRESS = #{indexAddress}
AND DISPOSOTION_STATE = '待确认'
and GATEWAY_ID = #{fanGatewayId}
AND (GATEWAY_ID = #{fanGatewayId} or GATEWAY_ID = #{syzGatewayId})
ORDER BY
sort DESC,
REC_DATE DESC
......@@ -1372,12 +1372,12 @@ FROM (
AND REC_DATE >= DATE_ADD( #{recDate}, INTERVAL - 12 hour )
AND ANALYSIS_TYPE = '按10分钟'
AND INDEX_ADDRESS = #{indexAddress}
AND GATEWAY_ID = #{fanGatewayId}
AND (GATEWAY_ID = #{fanGatewayId} or GATEWAY_ID = #{syzGatewayId})
</select>
<select id="getIsWarningByPointId" resultType="int">
select count(1) from ${tableName}
where INDEX_ADDRESS = #{indexAddress}
AND GATEWAY_ID = #{fanGatewayId}
AND (GATEWAY_ID = #{fanGatewayId} or GATEWAY_ID = #{syzGatewayId})
and DISPOSOTION_STATE = '待确认'
</select>
<select id="getStationIndexInfoByParam" resultType="java.util.Map">
......@@ -1770,7 +1770,7 @@ TIMESTAMPDIFF( MINUTE, #{startTime} , #{endTime})/10 >= @s-1
from fan_health_index_latest_data
where
INDEX_ADDRESS = #{indexAddress}
and GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
and ANALYSIS_OBJ_TYPE = '测点'
and ANALYSIS_TYPE = '按天'
limit 1
......@@ -1782,7 +1782,7 @@ TIMESTAMPDIFF( MINUTE, #{startTime} , #{endTime})/10 >= @s-1
from pv_health_index_latest_data
where
INDEX_ADDRESS = #{indexAddress}
and GATEWAY_ID = #{gatewayId}
AND (GATEWAY_ID = #{gatewayId} or GATEWAY_ID = #{syzGatewayId})
and ANALYSIS_OBJ_TYPE = '测点'
and ANALYSIS_TYPE = '按天'
limit 1
......
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