@@ -198,9 +192,9 @@ public class MonitorFanIndicatorImpl implements IMonitorFanIndicator {
...
@@ -198,9 +192,9 @@ public class MonitorFanIndicatorImpl implements IMonitorFanIndicator {
Page<IndexDto>page=newPage<>(current,size);
Page<IndexDto>page=newPage<>(current,size);
Stringsql="";
Stringsql="";
if(StringUtils.isNotEmpty(systemType)){
if(StringUtils.isNotEmpty(systemType)){
sql=String.format("SELECT equipmentIndexName, value, frontModule, unit FROM \"indicators_%s\" WHERE equipmentNumber = '%s' and frontModule =~/%s/ and systemType =~/%s/ ",stationBasic.getFanGatewayId(),equipNum,frontModule,systemType);
sql=String.format("SELECT equipmentIndexName, value, frontModule, unit,systemType FROM \"indicators_%s\" WHERE equipmentNumber = '%s' and frontModule =~/%s/ and systemType =~/%s/ ",stationBasic.getFanGatewayId(),equipNum,frontModule,systemType);
}else{
}else{
sql=String.format("SELECT equipmentIndexName, value, frontModule, unit FROM \"indicators_%s\" WHERE equipmentNumber = '%s' and frontModule =~/%s/",stationBasic.getFanGatewayId(),equipNum,frontModule);
sql=String.format("SELECT equipmentIndexName, value, frontModule, unit,systemType FROM \"indicators_%s\" WHERE equipmentNumber = '%s' and frontModule =~/%s/",stationBasic.getFanGatewayId(),equipNum,frontModule);
Stringsql=String.format("SELECT equipmentNumber, equipmentSpecificName, equipmentIndexName FROM \"indicators_%s\" WHERE equipmentNumber = '%s' and equipmentIndexName =~/^报警状态|停机状态|故障状态|待机状态|维护状态|正常发电状态$/ and value = 'true' order by time desc limit 1",stationBasic.getFanGatewayId(),equipNum);
Stringsql=String.format("SELECT equipmentNumber, equipmentSpecificName, equipmentIndexName FROM \"indicators_%s\" WHERE equipmentNumber = '%s' and equipmentIndexName =~/^报警状态|停机状态|故障状态|待机状态|维护状态|正常发电状态$/ and value = 'true' order by time desc limit 1",stationBasic.getFanGatewayId(),equipNum);
Stringsql=" SELECT displayName , value as state,equipmentIndexName FROM indicators_"+gatewayId+" WHERE frontModule =~/"+frontModule+"/ and systemType = '"+systemType+"'";
Stringsql=" SELECT displayName ,equipmentNumber , value as state,equipmentIndexName FROM indicators_"+gatewayId+" WHERE frontModule =~/"+frontModule+"/ and systemType = '"+systemType+"'";
if(null!=equipNum){
if(null!=equipNum){
sql=" SELECT displayName , value as state,equipmentIndexName FROM indicators_"+gatewayId+" WHERE frontModule =~/"+frontModule+"/ and systemType = '"+systemType+"' and equipmentNumber ='"+equipNum+"'";
sql=" SELECT displayName , equipmentNumber , value as state,equipmentIndexName FROM indicators_"+gatewayId+" WHERE frontModule =~/"+frontModule+"/ and systemType = '"+systemType+"' and equipmentNumber ='"+equipNum+"'";
Stringsql="SELECT value FROM indicators_"+stationCacheInfoDto.getBoosterGatewayId()+" WHERE equipmentIndexName='220kV夏雩线212线路测控装置PCS-9705TA有功功率一次值' or equipmentIndexName='南瑞光差保护_313P'";
Stringsql="SELECT value FROM indicators_"+stationCacheInfoDto.getBoosterGatewayId()+" WHERE equipmentIndexName='220kV夏雩线212线路测控装置PCS-9705TA有功功率一次值' or equipmentIndexName='南瑞光差保护_313P'";
Stringsql="SELECT * FROM indicators_"+gatewayId+" WHERE equipmentIndexName = '有功功率' or equipmentIndexName = '逆变器效率' or equipmentIndexName ='总直流功率' or equipmentIndexName ='日发电量' or equipmentIndexName ='总发电量' ";
Stringsql="SELECT * FROM indicators_"+gatewayId+" WHERE equipmentIndexName = '有功功率' or equipmentIndexName = '逆变器效率' or equipmentIndexName ='总直流功率' or equipmentIndexName ='日发电量' or equipmentIndexName ='总发电量' ";
// String sql = " SELECT * FROM indicators_" + gatewayId + " WHERE (equipmentIndexName ='待机' or equipmentIndexName ='故障停机' or equipmentIndexName ='告警运行' or equipmentIndexName ='限额运行' or equipmentIndexName ='停机') and value = 'true'";
// String sql = " SELECT * FROM indicators_" + gatewayId + " WHERE (equipmentIndexName ='待机' or equipmentIndexName ='故障停机' or equipmentIndexName ='告警运行' or equipmentIndexName ='限额运行' or equipmentIndexName ='停机') and value = 'true'";
Stringsql="SELECT * FROM indicators_"+stationCacheInfoDto.getFanGatewayId()+" WHERE equipmentIndexName =~/路电流/ and and equipmentNumber ='+"+equipNumber+"'";
Stringsql="SELECT * FROM indicators_"+stationCacheInfoDto.getFanGatewayId()+" WHERE equipmentIndexName =~/路电流/ and and equipmentNumber ='+"+equipNumber+"'";
Stringsql=" SELECT * FROM indicators_"+gatewayId+" WHERE (equipmentIndexName ='待机' or equipmentIndexName ='停机' or equipmentIndexName ='告警运行' or equipmentIndexName ='限额运行' or equipmentIndexName ='降额运行' or equipmentIndexName ='故障停机'or equipmentIndexName ='通讯故障'or equipmentIndexName ='运行') and value = 'true'";