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
9561ed36
Commit
9561ed36
authored
Oct 07, 2023
by
tangwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改有功功率
parent
9c2a2d70
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
49 additions
and
22 deletions
+49
-22
MonitorFanIdxController.java
.../module/jxiop/biz/controller/MonitorFanIdxController.java
+1
-9
MonitoringServiceImpl.java
.../module/jxiop/biz/service/impl/MonitoringServiceImpl.java
+48
-13
No files found.
amos-boot-system-jxiop/amos-boot-module-jxiop-monitor-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/controller/MonitorFanIdxController.java
View file @
9561ed36
...
...
@@ -229,15 +229,7 @@ public class MonitorFanIdxController extends BaseController {
List
<
ESEquipments
>
result1
=
commonService
.
getListDataByCondtions
(
queryCondtion1
,
null
,
ESEquipments
.
class
);
Map
<
String
,
List
<
String
>>
queryCondtion2
=
new
HashMap
<>();
queryCondtion2
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"南瑞光差保护_313P"
));
queryCondtion2
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getBoosterGatewayId
()));
List
<
ESEquipments
>
result2
=
commonService
.
getListDataByCondtions
(
queryCondtion2
,
null
,
ESEquipments
.
class
);
columnMap
.
put
(
"有功功率"
,
String
.
format
(
"%.2f"
,
(
result1
.
get
(
0
).
getValueF
()+
result2
.
get
(
0
).
getValueF
())/
1000
));
columnMap
.
put
(
"有功功率"
,
String
.
format
(
"%.2f"
,
result1
.
get
(
0
).
getValueF
()));
String
num
=
monitorFanIndicator
.
getEquipCount
(
gatewayId
,
"FDZ"
);
columnMap
.
put
(
"风机台数"
,
num
);
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-monitor-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/service/impl/MonitoringServiceImpl.java
View file @
9561ed36
...
...
@@ -450,24 +450,44 @@ public class MonitoringServiceImpl {
List
<
Map
<
String
,
Object
>>
mapList1
;
if
(
stationBasic
.
getStationType
().
equals
(
"FDZ"
))
{
Map
<
String
,
List
<
String
>>
queryCondtion
=
new
HashMap
<>();
queryCondtion
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"30秒平均风速"
,
"有功功率"
));
queryCondtion
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"30秒平均风速"
));
queryCondtion
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getFanGatewayId
()));
List
<
ESEquipments
>
result
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion
,
null
,
ESEquipments
.
class
);
homeMapStationInfoDto
.
setSpeendOrirradiate
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
commonServiceImpl
.
getAvagerByEquipmentIndxName
(
result
,
"30秒平均风速"
)));
homeMapStationInfoDto
.
setCurrentPower
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
commonServiceImpl
.
getSumByEquipmentIndxName
(
result
,
"有功功率"
)));
//homeMapStationInfoDto.setCurrentPower(String.format(CommonConstans.Twodecimalplaces, commonServiceImpl.getSumByEquipmentIndxName(result, "有功功率")));
Map
<
String
,
List
<
String
>>
queryCondtion1
=
new
HashMap
<>();
queryCondtion1
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getBoosterGatewayId
()));
queryCondtion1
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"220kV夏雩线212线路测控装置PCS-9705TA有功功率一次值"
));
List
<
ESEquipments
>
esEquipmentsList
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion1
,
null
,
ESEquipments
.
class
);
homeMapStationInfoDto
.
setCurrentPower
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
commonServiceImpl
.
getSumByEquipmentIndxName
(
esEquipmentsList
,
"220kV夏雩线212线路测控装置PCS-9705TA有功功率一次值"
)));
}
else
{
Map
<
String
,
List
<
String
>>
queryCondtion
=
new
HashMap
<>();
queryCondtion
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"有功功率"
));
queryCondtion
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getFanGatewayId
()));
Map
<
String
,
String
>
shouldQueryCondtion
=
new
HashMap
<>();
shouldQueryCondtion
.
put
(
CommonConstans
.
QueryStringFrontMoudle
,
"逆变器"
);
// Map<String, List<String>> queryCondtion = new HashMap<>();
// queryCondtion.put(CommonConstans.QueryStringEquipmentIndexName, Arrays.asList("有功功率"));
// queryCondtion.put(CommonConstans.QueryStringGateWayId, Arrays.asList(stationBasic.getFanGatewayId()));
// Map<String, String> shouldQueryCondtion = new HashMap<>();
// shouldQueryCondtion.put(CommonConstans.QueryStringFrontMoudle, "逆变器");
// List<ESEquipments> result = commonServiceImpl.getListDataByCondtions(queryCondtion, null, ESEquipments.class, shouldQueryCondtion);
//
// homeMapStationInfoDto.setCurrentPower(String.format(CommonConstans.Twodecimalplaces, commonServiceImpl.getSumByEquipmentIndxName(result, "有功功率")));
Map
<
String
,
List
<
String
>>
queryCondtion2
=
new
HashMap
<>();
queryCondtion2
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getBoosterGatewayId
()));
queryCondtion2
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"南瑞光差保护_313P"
));
List
<
ESEquipments
>
esEquipmentsList
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion2
,
null
,
ESEquipments
.
class
);
homeMapStationInfoDto
.
setCurrentPower
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
commonServiceImpl
.
getSumByEquipmentIndxName
(
esEquipmentsList
,
"南瑞光差保护_313P"
)));
Map
<
String
,
List
<
String
>>
queryCondtion1
=
new
HashMap
<>();
queryCondtion1
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"WTX-801_25_WTX-801_总辐射"
));
queryCondtion1
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getBoosterGatewayId
()));
List
<
ESEquipments
>
result
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion
,
null
,
ESEquipments
.
class
,
shouldQueryCondtion
);
List
<
ESEquipments
>
result1
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion1
,
null
,
ESEquipments
.
class
);
homeMapStationInfoDto
.
setSpeendOrirradiate
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
commonServiceImpl
.
getSumByEquipmentIndxName
(
result1
,
"WTX-801_25_WTX-801_总辐射"
)));
homeMapStationInfoDto
.
setCurrentPower
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
commonServiceImpl
.
getSumByEquipmentIndxName
(
result
,
"有功功率"
)));
}
StationCoordinate
stationCoordinate
=
stationCoordinateList
.
stream
().
filter
(
stationCoordinate1
->
stationCoordinate1
.
getStationId
().
equals
(
stationBasic
.
getSequenceNbr
())).
collect
(
Collectors
.
toList
()).
get
(
0
);
//获取场站经纬度
...
...
@@ -1206,19 +1226,34 @@ public class MonitoringServiceImpl {
public
HashMap
<
String
,
String
>
getActivePowerByAreaName
(
String
areaName
)
{
HashMap
<
String
,
String
>
hashMap
=
new
HashMap
<>();
AtomicReference
<
Double
>
total
=
new
AtomicReference
<>(
0.0
);
AtomicReference
<
Double
>
total1
=
new
AtomicReference
<>(
0.0
);
List
<
StationBasic
>
stationBasicListAll
=
new
ArrayList
<>();
Map
<
String
,
List
<
String
>>
queryCondtion
=
new
HashMap
<>();
Map
<
String
,
List
<
String
>>
queryCondtion1
=
new
HashMap
<>();
if
(!
ObjectUtils
.
isEmpty
(
areaName
))
{
stationBasicListAll
=
getListOfStationBasicByAreaName
(
areaName
);
}
else
{
stationBasicListAll
=
stationBasicMapper
.
selectList
(
new
QueryWrapper
<
StationBasic
>().
isNotNull
(
"fan_gateway_id"
));
}
stationBasicListAll
.
forEach
(
stationBasic
->
{
queryCondtion
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getFanGatewayId
()));
queryCondtion
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"有功功率"
));
List
<
ESEquipments
>
esEquipmentsList
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion
,
null
,
ESEquipments
.
class
);
total
.
updateAndGet
(
v
->
v
+
commonServiceImpl
.
getSumByEquipmentIndxName
(
esEquipmentsList
,
"有功功率"
));
if
(
stationBasic
.
getStationType
().
equals
(
"FDZ"
)){
queryCondtion
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getBoosterGatewayId
()));
queryCondtion
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"220kV夏雩线212线路测控装置PCS-9705TA有功功率一次值"
));
List
<
ESEquipments
>
esEquipmentsList
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion
,
null
,
ESEquipments
.
class
);
total
.
updateAndGet
(
v
->
v
+
commonServiceImpl
.
getSumByEquipmentIndxName
(
esEquipmentsList
,
"220kV夏雩线212线路测控装置PCS-9705TA有功功率一次值"
));
}
else
{
queryCondtion1
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationBasic
.
getBoosterGatewayId
()));
queryCondtion1
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"南瑞光差保护_313P"
));
List
<
ESEquipments
>
esEquipmentsList
=
commonServiceImpl
.
getListDataByCondtions
(
queryCondtion1
,
null
,
ESEquipments
.
class
);
total
.
updateAndGet
(
v
->
v
+
commonServiceImpl
.
getSumByEquipmentIndxName
(
esEquipmentsList
,
"南瑞光差保护_313P"
));
}
});
//有功功率换算
hashMap
.
put
(
"title"
,
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
total
.
get
()
/
1000
));
return
hashMap
;
...
...
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