Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
c784e203
Commit
c784e203
authored
Aug 07, 2023
by
chenzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
逆变器状态
parent
8caa8b83
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
72 additions
and
0 deletions
+72
-0
MonitorFanIndicatorImpl.java
...odule/jxiop/biz/service/impl/MonitorFanIndicatorImpl.java
+72
-0
No files found.
amos-boot-system-jxiop/amos-boot-module-jxiop-monitor-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/service/impl/MonitorFanIndicatorImpl.java
View file @
c784e203
...
@@ -1744,5 +1744,77 @@ public class MonitorFanIndicatorImpl implements IMonitorFanIndicator {
...
@@ -1744,5 +1744,77 @@ public class MonitorFanIndicatorImpl implements IMonitorFanIndicator {
return
resultMap
;
return
resultMap
;
}
}
public
Map
<
String
,
Object
>
nbqStatus
(
String
gatewayId
)
{
String
sql
=
" SELECT * FROM indicators_"
+
gatewayId
+
" WHERE (equipmentIndexName ='待机' or equipmentIndexName ='故障停机' or equipmentIndexName ='告警运行' or equipmentIndexName ='限额运行' or equipmentIndexName ='停机') and value = 'true'"
;
List
<
IndicatorsDto
>
indicatorsDtoList
=
influxDButils
.
getListData
(
sql
,
IndicatorsDto
.
class
);
int
djNum
=
0
;
int
gzNum
=
0
;
int
gjNum
=
0
;
int
xeNum
=
0
;
int
xdNum
=
0
;
int
txNum
=
0
;
int
tjNum
=
0
;
int
zcNum
=
0
;
Map
<
String
,
Object
>
numMap
=
new
HashMap
<>();
Set
<
String
>
equipNum
=
new
HashSet
<>();
for
(
IndicatorsDto
indicatorsDto
:
indicatorsDtoList
)
{
switch
(
indicatorsDto
.
getEquipmentIndexName
()){
case
"待机"
:
djNum
+=
1
;
break
;
case
"故障停机"
:
gzNum
+=
1
;
break
;
case
"告警运行"
:
gjNum
+=
1
;
break
;
case
"限额运行"
:
xeNum
+=
1
;
equipNum
.
add
(
indicatorsDto
.
getEquipmentNumber
());
break
;
case
"停机"
:
tjNum
+=
1
;
break
;
}
}
String
xesql
=
" SELECT * FROM indicators_"
+
gatewayId
+
" WHERE equipmentIndexName ='有功功率' and frontModule = '逆变器' and value < '0.5'"
;
List
<
IndicatorsDto
>
xeList
=
influxDButils
.
getListData
(
xesql
,
IndicatorsDto
.
class
);
for
(
IndicatorsDto
dto
:
xeList
)
{
if
(!
ValidationUtil
.
isEmpty
(
equipNum
)
&&
equipNum
.
contains
(
dto
.
getEquipmentNumber
())){
xdNum
+=
1
;
}
}
String
querySql
=
" SELECT * FROM indicators_"
+
gatewayId
+
" WHERE ( equipmentIndexName ='告警运行' or equipmentIndexName ='限额运行' ) and value != 'true'"
;
List
<
IndicatorsDto
>
queryList
=
influxDButils
.
getListData
(
querySql
,
IndicatorsDto
.
class
);
List
<
String
>
collect
=
queryList
.
stream
().
map
(
IndicatorsDto:
:
getEquipmentNumber
).
collect
(
Collectors
.
toList
());
Set
<
String
>
strings
=
new
HashSet
<>(
collect
);
zcNum
=
collect
.
size
()-
strings
.
size
();
String
querySql1
=
" SELECT * FROM indicators_"
+
gatewayId
+
" equipmentIndexName ='通讯异常' and value = 'true'"
;
List
<
IndicatorsDto
>
queryList1
=
influxDButils
.
getListData
(
querySql1
,
IndicatorsDto
.
class
);
List
<
String
>
collect1
=
queryList
.
stream
().
map
(
IndicatorsDto:
:
getEquipmentNumber
).
collect
(
Collectors
.
toList
());
Set
<
String
>
strings1
=
new
HashSet
<>(
collect
);
txNum
=
collect
.
size
()-
strings
.
size
();
numMap
.
put
(
"djNum"
,
djNum
);
numMap
.
put
(
"gzNum"
,
gzNum
);
numMap
.
put
(
"gjNum"
,
gjNum
);
numMap
.
put
(
"xeNum"
,
xeNum
);
numMap
.
put
(
"xdNum"
,
xdNum
);
numMap
.
put
(
"txNum"
,
txNum
);
numMap
.
put
(
"tjNum"
,
tjNum
);
numMap
.
put
(
"zcNum"
,
zcNum
);
return
numMap
;
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment