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
7bf1379a
Commit
7bf1379a
authored
Oct 16, 2023
by
xixinzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug修改
parent
3f2eb829
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
KsolarDataAcquisitionServiceImpl.java
...i/face/service/impl/KsolarDataAcquisitionServiceImpl.java
+7
-3
No files found.
amos-boot-data/amos-boot-data-housepvapi/src/main/java/com/yeejoin/amos/api/householdapi/face/service/impl/KsolarDataAcquisitionServiceImpl.java
View file @
7bf1379a
...
...
@@ -120,6 +120,7 @@ public class KsolarDataAcquisitionServiceImpl implements KSolarDataAcquisitionSe
for
(
String
stationId
:
stationIds
)
{
LambdaQueryWrapper
<
KsolarStationList
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
eq
(
KsolarStationList:
:
getStationId
,
stationId
);
wrapper
.
orderByDesc
(
KsolarStationList:
:
getCreatedTime
);
List
<
KsolarStationList
>
ksolarStationLists
=
kSolarStationMapper
.
selectList
(
wrapper
);
if
(!
CollectionUtils
.
isEmpty
(
ksolarStationLists
))
{
KsolarStationList
ksolarStation
=
ksolarStationLists
.
get
(
0
);
...
...
@@ -170,11 +171,11 @@ public class KsolarDataAcquisitionServiceImpl implements KSolarDataAcquisitionSe
jpStation
.
setState
(
KSolarConstant
.
stationStaus
.
get
(
String
.
valueOf
(
ksolarStation
.
getStatus
())));
jpStation
.
setRealTimePower
(
ksolarStation
.
getPowerInter
());
jpStation
.
setDayGenerate
(
ksolarStation
.
getDayGeneration
());
jpStation
.
setDayGenerate
(
ksolarStation
.
getDayGeneration
()
*
KSolarConstant
.
kwhToMwh
);
jpStation
.
setAccumulatedPower
(
ksolarStation
.
getTotalGeneration
());
jpStation
.
setArea
(
ksolarStation
.
getAddress
());
// 日收益
jpStation
.
setDayIncome
(
stationEarn
.
getDayEarn
()
*
KSolarConstant
.
kwhToMwh
);
jpStation
.
setDayIncome
(
stationEarn
.
getDayEarn
());
// 月发电量
jpStation
.
setMonthGenerate
(
stationEarn
.
getMonthGeneration
()
*
KSolarConstant
.
kwhToMwh
);
// 年发电量
...
...
@@ -331,6 +332,7 @@ public class KsolarDataAcquisitionServiceImpl implements KSolarDataAcquisitionSe
for
(
String
stationId
:
stationIds
)
{
LambdaQueryWrapper
<
KsolarStationList
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
eq
(
KsolarStationList:
:
getStationId
,
stationId
);
wrapper
.
orderByDesc
(
KsolarStationList:
:
getCreatedTime
);
List
<
KsolarStationList
>
ksolarStationLists
=
kSolarStationMapper
.
selectList
(
wrapper
);
if
(!
CollectionUtils
.
isEmpty
(
ksolarStationLists
))
{
KsolarStationList
ksolarStationList
=
ksolarStationLists
.
get
(
0
);
...
...
@@ -416,6 +418,7 @@ public class KsolarDataAcquisitionServiceImpl implements KSolarDataAcquisitionSe
collectIds
.
forEach
(
collectId
->
{
LambdaQueryWrapper
<
KsolarStationCollectList
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
eq
(
KsolarStationCollectList:
:
getCollectId
,
collectId
);
wrapper
.
orderByDesc
(
KsolarStationCollectList:
:
getCreatedTime
);
List
<
KsolarStationCollectList
>
ksolarStationCollectLists
=
ksolarStationCollectListMapper
.
selectList
(
wrapper
);
if
(!
CollectionUtils
.
isEmpty
(
ksolarStationCollectLists
))
{
KsolarStationCollectList
ksolarStationCollectList
=
ksolarStationCollectLists
.
get
(
0
);
...
...
@@ -461,7 +464,7 @@ public class KsolarDataAcquisitionServiceImpl implements KSolarDataAcquisitionSe
jpInverter
.
setUpdateTime
(
new
Date
());
jpInverter
.
setCurrentPower
(
ksolarStationCollectData
.
getPowerApparent
());
jpInverter
.
setDayPowerGeneration
(
ksolarStationCollectData
.
getDayGeneration
());
jpInverter
.
setDayPowerGeneration
(
ksolarStationCollectData
.
getDayGeneration
()
*
KSolarConstant
.
kwhToMwh
);
jpInverter
.
setMonthPowerGeneration
(
ksolarStationCollectData
.
getMonthGeneration
()
*
KSolarConstant
.
kwhToMwh
);
jpInverter
.
setYearPowerGeneration
(
ksolarStationCollectData
.
getYearGeneration
()
*
KSolarConstant
.
kwhToMwh
);
jpInverter
.
setTotalPowerGeneration
(
ksolarStationCollectData
.
getTotalGeneration
()
*
KSolarConstant
.
kwhToMwh
);
...
...
@@ -470,6 +473,7 @@ public class KsolarDataAcquisitionServiceImpl implements KSolarDataAcquisitionSe
jpInverter
.
setThirdStationId
(
ksolarStationCollectList
.
getThirdStationId
());
jpInverter
.
setThirdCode
(
PVProducerInfoEnum
.
KSOLAR
.
getCode
());
jpInverter
.
setStationName
(
ksolarStationCollectList
.
getStationName
());
jpInverter
.
setAddr
(
ksolarStationCollectList
.
getAddress
());
if
(!
ObjectUtils
.
isEmpty
(
jpInverter
.
getSequenceNbr
()))
{
jpInverterMapper
.
updateById
(
jpInverter
);
}
else
{
...
...
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