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
6ddd51aa
Commit
6ddd51aa
authored
Apr 07, 2024
by
caotao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
运行监盘地图与电量指标运行数据江西区域电量指标完成情况数据源调整
parent
03b1d875
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
58 additions
and
79 deletions
+58
-79
BuDunStationDetailInfo.java
...mos/boot/module/jxiop/api/dto/BuDunStationDetailInfo.java
+13
-0
Constants.java
...om/yeejoin/amos/boot/module/jxiop/api/util/Constants.java
+1
-0
MonitorService.java
...in/amos/boot/module/jxiop/biz/service/MonitorService.java
+2
-2
MonitorServiceImpl.java
...oot/module/jxiop/biz/service/impl/MonitorServiceImpl.java
+42
-77
No files found.
amos-boot-system-jxiop/amos-boot-module-jxiop-api/src/main/java/com/yeejoin/amos/boot/module/jxiop/api/dto/BuDunStationDetailInfo.java
0 → 100644
View file @
6ddd51aa
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jxiop
.
api
.
dto
;
import
lombok.Data
;
@Data
public
class
BuDunStationDetailInfo
{
private
String
station_name
;
private
Double
actual_installed_capacity
;
private
Double
year
;
private
Double
month
;
private
Double
day
;
private
Double
wind_as_irradiance
;
}
amos-boot-system-jxiop/amos-boot-module-jxiop-api/src/main/java/com/yeejoin/amos/boot/module/jxiop/api/util/Constants.java
View file @
6ddd51aa
...
@@ -79,6 +79,7 @@ public class Constants {
...
@@ -79,6 +79,7 @@ public class Constants {
public
static
final
String
get_month_top_url
=
"method=scene_screen.data_interface.get_month_top"
;
public
static
final
String
get_month_top_url
=
"method=scene_screen.data_interface.get_month_top"
;
public
static
final
String
get_hours_num_top
=
"method=scene_screen.data_interface.get_hours_num_top"
;
public
static
final
String
get_hours_num_top
=
"method=scene_screen.data_interface.get_hours_num_top"
;
public
static
final
String
get_generated_quota_trend
=
"method=scene_screen.data_interface.get_generated_quota_trend"
;
public
static
final
String
get_generated_quota_trend
=
"method=scene_screen.data_interface.get_generated_quota_trend"
;
public
static
final
String
get_province_station_item
=
"method=scene_screen.data_interface.get_province_station_item"
;
public
static
final
String
resovleRule_data
=
"data"
;
public
static
final
String
resovleRule_data
=
"data"
;
public
static
final
String
areaChinese
=
"区域"
;
public
static
final
String
areaChinese
=
"区域"
;
}
}
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-monitor-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/service/MonitorService.java
View file @
6ddd51aa
...
@@ -59,6 +59,6 @@ public interface MonitorService {
...
@@ -59,6 +59,6 @@ public interface MonitorService {
* @return
* @return
*/
*/
public
Page
<
HashMap
<
String
,
String
>>
getPowerGenerationTrendsOfCompletionTopFive
(
String
areaName
);
Page
<
HashMap
<
String
,
String
>>
getPowerGenerationTrendsOfCompletionTopFive
(
String
areaName
);
public
Page
<
HashMap
<
String
,
String
>>
getPowerGenerationTrendsOfCompletionTopThree
(
String
tabValue
,
String
areaName
);
Page
<
HashMap
<
String
,
String
>>
getPowerGenerationTrendsOfCompletionTopThree
(
String
tabValue
,
String
areaName
);
}
}
amos-boot-system-jxiop/amos-boot-module-jxiop-monitor-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/service/impl/MonitorServiceImpl.java
View file @
6ddd51aa
...
@@ -3,10 +3,7 @@ package com.yeejoin.amos.boot.module.jxiop.biz.service.impl;
...
@@ -3,10 +3,7 @@ package com.yeejoin.amos.boot.module.jxiop.biz.service.impl;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSON
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.jxiop.api.dto.BuDunGenDto
;
import
com.yeejoin.amos.boot.module.jxiop.api.dto.*
;
import
com.yeejoin.amos.boot.module.jxiop.api.dto.BudunMonthTrendDto
;
import
com.yeejoin.amos.boot.module.jxiop.api.dto.BudunStationValueDto
;
import
com.yeejoin.amos.boot.module.jxiop.api.dto.BuDunPvFanDto
;
import
com.yeejoin.amos.boot.module.jxiop.api.entity.*
;
import
com.yeejoin.amos.boot.module.jxiop.api.entity.*
;
import
com.yeejoin.amos.boot.module.jxiop.api.mapper.*
;
import
com.yeejoin.amos.boot.module.jxiop.api.mapper.*
;
import
com.yeejoin.amos.boot.module.jxiop.api.util.Constants
;
import
com.yeejoin.amos.boot.module.jxiop.api.util.Constants
;
...
@@ -245,6 +242,8 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -245,6 +242,8 @@ public class MonitorServiceImpl implements MonitorService {
}
}
}
}
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_province_station_item
+
"&provinceName"
+
provinceName
;
List
<
BuDunStationDetailInfo
>
buDunStationDetailInfos
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunStationDetailInfo
.
class
);
List
<
CoreValuesDto
>
coreValuesDtos
=
coreCommonService
.
getValuesByStationNamesAndPointsNames
(
null
,
null
);
List
<
CoreValuesDto
>
coreValuesDtos
=
coreCommonService
.
getValuesByStationNamesAndPointsNames
(
null
,
null
);
String
finalProvinceName
=
provinceName
;
String
finalProvinceName
=
provinceName
;
if
(!
ObjectUtils
.
isEmpty
(
type
)
&&
type
.
equals
(
"station"
))
{
if
(!
ObjectUtils
.
isEmpty
(
type
)
&&
type
.
equals
(
"station"
))
{
...
@@ -267,11 +266,17 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -267,11 +266,17 @@ public class MonitorServiceImpl implements MonitorService {
List
<
CoreValuesDto
>
coreValuesDtoList
=
coreValuesDtos
.
stream
().
filter
(
coreValuesDto
->
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getStationCoreName
())
||
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getBoosterCoreName
())).
collect
(
Collectors
.
toList
());
List
<
CoreValuesDto
>
coreValuesDtoList
=
coreValuesDtos
.
stream
().
filter
(
coreValuesDto
->
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getStationCoreName
())
||
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getBoosterCoreName
())).
collect
(
Collectors
.
toList
());
if
(
coreValuesDtoList
!=
null
&&
coreValuesDtoList
.
size
()
>
0
)
{
if
(
coreValuesDtoList
!=
null
&&
coreValuesDtoList
.
size
()
>
0
)
{
speendOrirradiate
=
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
coreCommonService
.
getAverageOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
WIND_SPEED_THIRTY_SECONDS
));
speendOrirradiate
=
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
coreCommonService
.
getAverageOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
WIND_SPEED_THIRTY_SECONDS
));
}
else
{
BuDunStationDetailInfo
buDunStationDetailInfo
=
buDunStationDetailInfos
.
stream
().
filter
(
buDunStationDetailInfo1
->
buDunStationDetailInfo1
.
getStation_name
().
contains
(
stationCacheInfoDto
.
getStationName
().
replace
(
"电站"
,
""
).
replace
(
"电场"
,
""
))).
findFirst
().
get
();
speendOrirradiate
=
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
buDunStationDetailInfo
.
getWind_as_irradiance
());
}
}
}
else
if
(
stationCacheInfoDto
.
getStationType
().
contains
(
"GFDZ"
)
&&
stationCacheInfoDto
.
getStationCoreName
()
!=
null
&&
stationCacheInfoDto
.
getBoosterCoreName
()
!=
null
)
{
}
else
if
(
stationCacheInfoDto
.
getStationType
().
contains
(
"GFDZ"
)
&&
stationCacheInfoDto
.
getStationCoreName
()
!=
null
&&
stationCacheInfoDto
.
getBoosterCoreName
()
!=
null
)
{
List
<
CoreValuesDto
>
coreValuesDtoList
=
coreValuesDtos
.
stream
().
filter
(
coreValuesDto
->
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getStationCoreName
())
||
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getBoosterCoreName
())).
collect
(
Collectors
.
toList
());
List
<
CoreValuesDto
>
coreValuesDtoList
=
coreValuesDtos
.
stream
().
filter
(
coreValuesDto
->
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getStationCoreName
())
||
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getBoosterCoreName
())).
collect
(
Collectors
.
toList
());
if
(
coreValuesDtoList
!=
null
&&
coreValuesDtoList
.
size
()
>
0
)
{
if
(
coreValuesDtoList
!=
null
&&
coreValuesDtoList
.
size
()
>
0
)
{
speendOrirradiate
=
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
coreCommonService
.
getAverageOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
TOTAL_RADIATION
));
speendOrirradiate
=
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
coreCommonService
.
getAverageOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
TOTAL_RADIATION
));
}
else
{
BuDunStationDetailInfo
buDunStationDetailInfo
=
buDunStationDetailInfos
.
stream
().
filter
(
buDunStationDetailInfo1
->
buDunStationDetailInfo1
.
getStation_name
().
contains
(
stationCacheInfoDto
.
getStationName
().
replace
(
"电站"
,
""
).
replace
(
"电场"
,
""
))).
findFirst
().
get
();
speendOrirradiate
=
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
buDunStationDetailInfo
.
getWind_as_irradiance
());
}
}
}
}
...
@@ -350,66 +355,27 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -350,66 +355,27 @@ public class MonitorServiceImpl implements MonitorService {
//年发电量
//年发电量
AtomicReference
<
Double
>
fdzannualPower
=
new
AtomicReference
<>(
0.0
);
AtomicReference
<
Double
>
fdzannualPower
=
new
AtomicReference
<>(
0.0
);
AtomicReference
<
Double
>
gfzannualPower
=
new
AtomicReference
<>(
0.0
);
AtomicReference
<
Double
>
gfzannualPower
=
new
AtomicReference
<>(
0.0
);
List
<
CoreValuesDto
>
coreValuesDtos
=
coreCommonService
.
getValuesByStationNamesAndPointsNames
(
null
,
null
);
List
<
CoreValuesDto
>
coreValuesDtos
=
coreCommonService
.
getValuesByStationNamesAndPointsNames
(
null
,
null
);
//遍历列表
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_province_station_item
+
"&provinceName"
+
provinceName
;
stationCacheInfoDtos
.
forEach
(
stationCacheInfoDto
->
{
List
<
BuDunStationDetailInfo
>
buDunStationDetailInfos
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunStationDetailInfo
.
class
);
CompletionOfPowerIndicatorsDto
completionOfPowerIndicatorsDto
=
new
CompletionOfPowerIndicatorsDto
();
if
(
buDunStationDetailInfos
.
size
()
>
0
)
{
completionOfPowerIndicatorsDto
.
setStationName
(
stationCacheInfoDto
.
getStationName
());
buDunStationDetailInfos
.
forEach
(
buDunStationDetailInfo
->
{
completionOfPowerIndicatorsDto
.
setInstallCapactity
(
stationCacheInfoDto
.
getInstalledCapacity
());
CompletionOfPowerIndicatorsDto
completionOfPowerIndicatorsDto
=
new
CompletionOfPowerIndicatorsDto
();
try
{
completionOfPowerIndicatorsDto
.
setStationName
(
buDunStationDetailInfo
.
getStation_name
());
if
(
stationCacheInfoDto
.
getStationType
().
equals
(
"FDZ"
)
&&
stationCacheInfoDto
.
getStationCoreName
()
!=
null
&&
stationCacheInfoDto
.
getBoosterCoreName
()
!=
null
)
{
completionOfPowerIndicatorsDto
.
setInstallCapactity
(
String
.
valueOf
(
buDunStationDetailInfo
.
getActual_installed_capacity
()));
//用于组装-es查询条件
completionOfPowerIndicatorsDto
.
setWindSpeedOrIrradiance
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
buDunStationDetailInfo
.
getWind_as_irradiance
()));
completionOfPowerIndicatorsDto
.
setDailyPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
buDunStationDetailInfo
.
getDay
()));
completionOfPowerIndicatorsDto
.
setMonthlyPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
buDunStationDetailInfo
.
getMonth
()));
completionOfPowerIndicatorsDto
.
setAnnualPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
buDunStationDetailInfo
.
getYear
()));
StationCacheInfoDto
stationCacheInfoDto
=
stationCacheInfoDtoList
.
stream
().
filter
(
stationCacheInfoDto1
->
stationCacheInfoDto1
.
getStationName
().
contains
(
buDunStationDetailInfo
.
getStation_name
().
replace
(
"电场"
,
""
).
replace
(
"电站"
,
""
))).
findFirst
().
get
();
if
(
stationCacheInfoDto
.
getStationCoreName
()
!=
null
&&
stationCacheInfoDto
.
getBoosterCoreName
()
!=
null
)
{
List
<
CoreValuesDto
>
coreValuesDtoList
=
coreValuesDtos
.
stream
().
filter
(
coreValuesDto
->
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getStationCoreName
())
||
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getBoosterCoreName
())).
collect
(
Collectors
.
toList
());
List
<
CoreValuesDto
>
coreValuesDtoList
=
coreValuesDtos
.
stream
().
filter
(
coreValuesDto
->
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getStationCoreName
())
||
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getBoosterCoreName
())).
collect
(
Collectors
.
toList
());
if
(
coreValuesDtoList
!=
null
&&
coreValuesDtoList
.
size
()
>
0
)
{
completionOfPowerIndicatorsDto
.
setActivePower
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
ACTIVE_POWER
))));
completionOfPowerIndicatorsDto
.
setWindSpeedOrIrradiance
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
WIND_SPEED_THIRTY_SECONDS
)));
}
else
{
completionOfPowerIndicatorsDto
.
setDailyPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
DAY_POWER_GENERATION
)));
completionOfPowerIndicatorsDto
.
setActivePower
(
"--"
);
completionOfPowerIndicatorsDto
.
setMonthlyPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
MONTH_POWER_GENERATION
)));
completionOfPowerIndicatorsDto
.
setAnnualPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
YEAR_POWER_GENERATION
)));
dailyPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
DAY_POWER_GENERATION
)));
monthlyPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
MONTH_POWER_GENERATION
)));
annualPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
YEAR_POWER_GENERATION
)));
fdzannualPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
YEAR_POWER_GENERATION
)));
completionOfPowerIndicatorsDto
.
setActivePower
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
ACTIVE_POWER
))));
fdzInstallCapacity
.
updateAndGet
(
v
->
v
+
Double
.
parseDouble
(
stationCacheInfoDto
.
getInstalledCapacity
()));
}
}
else
if
(
stationCacheInfoDto
.
getStationType
().
contains
(
"GFDZ"
)
&&
stationCacheInfoDto
.
getStationCoreName
()
!=
null
&&
stationCacheInfoDto
.
getBoosterCoreName
()
!=
null
)
{
Map
<
String
,
List
<
String
>>
queryCondtion
=
new
HashMap
<>();
queryCondtion
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
CommonConstans
.
taiHeGenIndicator
);
queryCondtion
.
put
(
CommonConstans
.
QueryStringGateWayId
,
Arrays
.
asList
(
stationCacheInfoDto
.
getBoosterGatewayId
()));
Map
<
String
,
List
<
String
>>
queryCondtion1
=
new
HashMap
<>();
queryCondtion1
.
put
(
CommonConstans
.
QueryStringEquipmentIndexName
,
Arrays
.
asList
(
"WTX-801_25_WTX-801_总辐射"
,
"南瑞光差保护_313P"
));
List
<
CoreValuesDto
>
coreValuesDtoList
=
coreValuesDtos
.
stream
().
filter
(
coreValuesDto
->
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getStationCoreName
())
||
coreValuesDto
.
getName
().
equals
(
stationCacheInfoDto
.
getBoosterCoreName
())).
collect
(
Collectors
.
toList
());
if
(
coreValuesDtoList
!=
null
&&
coreValuesDtoList
.
size
()
>
0
)
{
completionOfPowerIndicatorsDto
.
setDailyPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
DAY_POWER_GENERATION
)));
completionOfPowerIndicatorsDto
.
setMonthlyPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
MONTH_POWER_GENERATION
)));
completionOfPowerIndicatorsDto
.
setAnnualPower
(
String
.
format
(
CommonConstans
.
Fourdecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
YEAR_POWER_GENERATION
)));
dailyPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
DAY_POWER_GENERATION
)));
monthlyPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
MONTH_POWER_GENERATION
)));
annualPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
YEAR_POWER_GENERATION
)));
gfzannualPower
.
updateAndGet
(
v
->
v
+
keepFourdecimalPlaces
(
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
YEAR_POWER_GENERATION
)));
completionOfPowerIndicatorsDto
.
setWindSpeedOrIrradiance
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
TOTAL_RADIATION
)));
completionOfPowerIndicatorsDto
.
setActivePower
(
String
.
format
(
CommonConstans
.
Twodecimalplaces
,
coreCommonService
.
getSumOfByPointName
(
coreValuesDtoList
,
CommonConstans
.
ACTIVE_POWER
)));
gfzinstallCapacity
.
updateAndGet
(
v
->
v
+
Double
.
parseDouble
(
stationCacheInfoDto
.
getInstalledCapacity
()));
}
}
else
{
completionOfPowerIndicatorsDto
.
setWindSpeedOrIrradiance
(
"----"
);
completionOfPowerIndicatorsDto
.
setActivePower
(
"----"
);
completionOfPowerIndicatorsDto
.
setDailyPower
(
"----"
);
completionOfPowerIndicatorsDto
.
setMonthlyPower
(
"----"
);
completionOfPowerIndicatorsDto
.
setAnnualPower
(
"----"
);
completionOfPowerIndicatorsDto
.
setInstallCapactity
(
"----"
);
}
}
}
catch
(
Exception
exception
)
{
});
completionOfPowerIndicatorsDto
.
setWindSpeedOrIrradiance
(
"----"
);
}
completionOfPowerIndicatorsDto
.
setActivePower
(
"----"
);
completionOfPowerIndicatorsDto
.
setDailyPower
(
"----"
);
completionOfPowerIndicatorsDto
.
setMonthlyPower
(
"----"
);
completionOfPowerIndicatorsDto
.
setAnnualPower
(
"----"
);
completionOfPowerIndicatorsDto
.
setInstallCapactity
(
"----"
);
}
completionOfPowerIndicatorsDtoList
.
add
(
completionOfPowerIndicatorsDto
);
});
String
provincelUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_province_item_url
+
"&provinceName="
+
provinceName
;
String
provincelUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_province_item_url
+
"&provinceName="
+
provinceName
;
List
<
BuDunGenDto
>
provinceDtos
=
httpRequestUtil
.
getResPonse
(
provincelUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunGenDto
.
class
);
List
<
BuDunGenDto
>
provinceDtos
=
httpRequestUtil
.
getResPonse
(
provincelUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunGenDto
.
class
);
if
(
provinceDtos
.
size
()
>
0
)
{
if
(
provinceDtos
.
size
()
>
0
)
{
...
@@ -561,7 +527,7 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -561,7 +527,7 @@ public class MonitorServiceImpl implements MonitorService {
if
(!
areaName
.
contains
(
Constants
.
areaChinese
))
{
if
(!
areaName
.
contains
(
Constants
.
areaChinese
))
{
areaName
=
areaName
+
Constants
.
areaChinese
;
areaName
=
areaName
+
Constants
.
areaChinese
;
}
}
requestUrl
=
requestUrl
+
"&areaName="
+
areaName
;
requestUrl
=
requestUrl
+
"&areaName="
+
areaName
;
}
}
List
<
BuDunGenDto
>
buDunGenDtos
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunGenDto
.
class
);
List
<
BuDunGenDto
>
buDunGenDtos
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunGenDto
.
class
);
if
(
buDunGenDtos
.
size
()
>
0
)
{
if
(
buDunGenDtos
.
size
()
>
0
)
{
...
@@ -604,18 +570,18 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -604,18 +570,18 @@ public class MonitorServiceImpl implements MonitorService {
public
Page
<
HashMap
<
String
,
String
>>
getPowerGenerationTrendsOfCompletionTopFive
(
String
areaName
)
{
public
Page
<
HashMap
<
String
,
String
>>
getPowerGenerationTrendsOfCompletionTopFive
(
String
areaName
)
{
Page
<
HashMap
<
String
,
String
>>
hashMapPage
=
new
Page
<>(
1
,
5
);
Page
<
HashMap
<
String
,
String
>>
hashMapPage
=
new
Page
<>(
1
,
5
);
List
<
HashMap
<
String
,
String
>>
mapList
=
new
ArrayList
<>();
List
<
HashMap
<
String
,
String
>>
mapList
=
new
ArrayList
<>();
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_month_top_url
+
"&topValue=5"
;
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_month_top_url
+
"&topValue=5"
;
if
(!
ObjectUtils
.
isEmpty
(
areaName
))
{
if
(!
ObjectUtils
.
isEmpty
(
areaName
))
{
if
(
areaName
.
contains
(
Constants
.
areaChinese
))
{
if
(
areaName
.
contains
(
Constants
.
areaChinese
))
{
areaName
=
areaName
+
Constants
.
areaChinese
;
areaName
=
areaName
+
Constants
.
areaChinese
;
}
}
requestUrl
=
requestUrl
+
"&areaName="
+
areaName
;
requestUrl
=
requestUrl
+
"&areaName="
+
areaName
;
}
}
List
<
BudunStationValueDto
>
budunStationValueDtoList
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BudunStationValueDto
.
class
);
List
<
BudunStationValueDto
>
budunStationValueDtoList
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BudunStationValueDto
.
class
);
HashMap
<
String
,
List
<
String
>>
hashMap
=
new
HashMap
<>();
HashMap
<
String
,
List
<
String
>>
hashMap
=
new
HashMap
<>();
budunStationValueDtoList
.
forEach
(
budunStationValueDto
->
{
budunStationValueDtoList
.
forEach
(
budunStationValueDto
->
{
HashMap
<
String
,
String
>
hashMap1
=
new
HashMap
<>();
HashMap
<
String
,
String
>
hashMap1
=
new
HashMap
<>();
hashMap1
.
put
(
"stationName"
,
budunStationValueDto
.
getStation_name
());
hashMap1
.
put
(
"stationName"
,
budunStationValueDto
.
getStation_name
());
hashMap1
.
put
(
"value"
,
budunStationValueDto
.
getValue
()
+
"%"
);
hashMap1
.
put
(
"value"
,
budunStationValueDto
.
getValue
()
+
"%"
);
hashMap1
.
put
(
"value1"
,
String
.
valueOf
(
budunStationValueDto
.
getValue
()));
hashMap1
.
put
(
"value1"
,
String
.
valueOf
(
budunStationValueDto
.
getValue
()));
mapList
.
add
(
hashMap1
);
mapList
.
add
(
hashMap1
);
...
@@ -671,17 +637,17 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -671,17 +637,17 @@ public class MonitorServiceImpl implements MonitorService {
List
<
HashMap
<
String
,
String
>>
mapList
=
new
ArrayList
<>();
List
<
HashMap
<
String
,
String
>>
mapList
=
new
ArrayList
<>();
List
<
StationBasic
>
fdzList
=
new
ArrayList
<>();
List
<
StationBasic
>
fdzList
=
new
ArrayList
<>();
List
<
StationBasic
>
gfdzlist
=
new
ArrayList
<>();
List
<
StationBasic
>
gfdzlist
=
new
ArrayList
<>();
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_hours_num_top
+
"&topValue=3&tabValue="
+
tabValue
;
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_hours_num_top
+
"&topValue=3&tabValue="
+
tabValue
;
if
(!
ObjectUtils
.
isEmpty
(
areaName
))
{
if
(!
ObjectUtils
.
isEmpty
(
areaName
))
{
if
(
areaName
.
contains
(
Constants
.
areaChinese
))
{
if
(
areaName
.
contains
(
Constants
.
areaChinese
))
{
areaName
=
areaName
+
Constants
.
areaChinese
;
areaName
=
areaName
+
Constants
.
areaChinese
;
}
}
requestUrl
=
requestUrl
+
"&areaName="
+
areaName
;
requestUrl
=
requestUrl
+
"&areaName="
+
areaName
;
}
}
List
<
BuDunPvFanDto
>
buDunPvFanDtos
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunPvFanDto
.
class
);
List
<
BuDunPvFanDto
>
buDunPvFanDtos
=
httpRequestUtil
.
getResPonse
(
requestUrl
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
,
BuDunPvFanDto
.
class
);
if
(
buDunPvFanDtos
.
size
()>
0
)
{
if
(
buDunPvFanDtos
.
size
()
>
0
)
{
BuDunPvFanDto
buDunPvFanDto
=
buDunPvFanDtos
.
get
(
0
);
BuDunPvFanDto
buDunPvFanDto
=
buDunPvFanDtos
.
get
(
0
);
int
length
=
buDunPvFanDto
.
getFan
().
size
()>=
buDunPvFanDto
.
getPv
().
size
()?
buDunPvFanDto
.
getFan
().
size
():
buDunPvFanDto
.
getPv
().
size
();
int
length
=
buDunPvFanDto
.
getFan
().
size
()
>=
buDunPvFanDto
.
getPv
().
size
()
?
buDunPvFanDto
.
getFan
().
size
()
:
buDunPvFanDto
.
getPv
().
size
();
for
(
int
i
=
0
;
i
<
length
;
i
++)
{
for
(
int
i
=
0
;
i
<
length
;
i
++)
{
HashMap
<
String
,
String
>
stringHashMap
=
new
HashMap
<>();
HashMap
<
String
,
String
>
stringHashMap
=
new
HashMap
<>();
stringHashMap
.
put
(
"sortNumber"
,
String
.
valueOf
(
i
+
1
));
stringHashMap
.
put
(
"sortNumber"
,
String
.
valueOf
(
i
+
1
));
...
@@ -696,7 +662,7 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -696,7 +662,7 @@ public class MonitorServiceImpl implements MonitorService {
if
(
i
<
(
buDunPvFanDto
.
getPv
().
size
()))
{
if
(
i
<
(
buDunPvFanDto
.
getPv
().
size
()))
{
BudunStationValueDto
budunStationValueDto
=
buDunPvFanDto
.
getPv
().
get
(
i
);
BudunStationValueDto
budunStationValueDto
=
buDunPvFanDto
.
getPv
().
get
(
i
);
stringHashMap
.
put
(
"stationName2"
,
budunStationValueDto
.
getStation_name
());
stringHashMap
.
put
(
"stationName2"
,
budunStationValueDto
.
getStation_name
());
stringHashMap
.
put
(
"hours2"
,
budunStationValueDto
.
getValue
()
+
"h"
);
stringHashMap
.
put
(
"hours2"
,
budunStationValueDto
.
getValue
()
+
"h"
);
}
else
{
}
else
{
stringHashMap
.
put
(
"stationName2"
,
""
);
stringHashMap
.
put
(
"stationName2"
,
""
);
stringHashMap
.
put
(
"hours2"
,
"0.00h"
);
stringHashMap
.
put
(
"hours2"
,
"0.00h"
);
...
@@ -711,5 +677,4 @@ public class MonitorServiceImpl implements MonitorService {
...
@@ -711,5 +677,4 @@ public class MonitorServiceImpl implements MonitorService {
}
}
}
}
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