Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-zx-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
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
Jobs
Commits
Open sidebar
项目统一框架
一体化_户用光伏项目代码
amos-boot-zx-biz
Commits
3a296cd3
Commit
3a296cd3
authored
Aug 01, 2024
by
hezhuozhi
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/developer' into developer
parents
d1d278cf
4d2f2329
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
19 deletions
+33
-19
TanYinDataAcquisitionServiceImpl.java
...i/face/service/impl/TanYinDataAcquisitionServiceImpl.java
+21
-7
MonitorServiceImpl.java
...oot/module/jxiop/biz/service/impl/MonitorServiceImpl.java
+1
-1
application-dev1.properties
...onitor-biz/src/main/resources/application-dev1.properties
+11
-11
No files found.
amos-boot-data/amos-boot-data-housepvapi/src/main/java/com/yeejoin/amos/api/householdapi/face/service/impl/TanYinDataAcquisitionServiceImpl.java
View file @
3a296cd3
...
...
@@ -178,7 +178,7 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
@Override
public
void
customerInfoList
()
{
try
{
String
startDate
=
LocalDate
.
now
().
minus
Day
s
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
String
startDate
=
LocalDate
.
now
().
minus
Month
s
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
String
endDate
=
LocalDate
.
now
().
plusDays
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
log
.
info
(
"-------碳银同步项目信息开始: {} ------- "
,
sdf
.
format
(
new
Date
()));
Map
<
String
,
Object
>
params
=
MapBuilder
.<
String
,
Object
>
create
()
...
...
@@ -465,7 +465,12 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
if
(
jpInverter
==
null
||
StringUtils
.
isEmpty
(
jpInverter
.
getSnCode
()))
{
return
;
}
String
startDate
=
LocalDate
.
now
().
minusWeeks
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
String
startDate
;
if
(
jpInverter
.
getUpdateTime
()
!=
null
)
{
startDate
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
).
format
(
jpInverter
.
getUpdateTime
());
}
else
{
startDate
=
LocalDate
.
now
().
minusMonths
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
}
String
endDate
=
LocalDate
.
now
().
plusDays
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
Map
<
String
,
Object
>
params
=
MapBuilder
.<
String
,
Object
>
create
()
.
put
(
"sn"
,
jpInverter
.
getSnCode
())
...
...
@@ -474,11 +479,19 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
.
put
(
"startDate"
,
startDate
)
.
put
(
"endDate"
,
endDate
).
build
();
PageInfo
<
TanYinAlramInfo
>
tanYinInveterInfo
=
tanYinApiUtils
.
postPage
(
"电站逆变器故障信息"
,
apiUrl
+
TanYinConstant
.
inverterAlramUrl
,
JSON
.
toJSONString
(
params
),
null
,
TanYinAlramInfo
.
class
);
List
<
TanYinAlramInfo
>
tanYinAlramInfos
=
tanYinInveterInfo
.
getList
();
if
(
CollectionUtils
.
isEmpty
(
tanYinAlramInfos
))
{
if
(
tanYinInveterInfo
==
null
||
CollectionUtils
.
isEmpty
(
tanYinInveterInfo
.
getList
()))
{
log
.
warn
(
"-------碳银同步电站逆变器故障信息结束: 未获取到逆变器故障信息 ------- "
);
return
;
}
List
<
TanYinAlramInfo
>
tanYinAlramInfos
=
new
ArrayList
<>();
tanYinAlramInfos
.
addAll
(
tanYinInveterInfo
.
getList
());
if
(
tanYinInveterInfo
.
getPages
()
>
1
)
{
for
(
int
pageNum
=
2
;
pageNum
<
tanYinInveterInfo
.
getPages
();
pageNum
++)
{
params
.
put
(
"pageNo"
,
pageNum
);
PageInfo
<
TanYinAlramInfo
>
tanYinInveterInfoPage
=
tanYinApiUtils
.
postPage
(
"电站逆变器故障信息"
,
apiUrl
+
TanYinConstant
.
inverterAlramUrl
,
JSON
.
toJSONString
(
params
),
null
,
TanYinAlramInfo
.
class
);
tanYinAlramInfos
.
addAll
(
tanYinInveterInfoPage
.
getList
());
}
}
for
(
TanYinAlramInfo
tanYinAlramInfo
:
tanYinAlramInfos
)
{
tanYinAlramInfo
.
setCreateTime
(
System
.
currentTimeMillis
());
tanYinAlramInfoMapper
.
insert
(
tanYinAlramInfo
);
...
...
@@ -486,7 +499,9 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
HYGFJPInverterWarn
hygfjpInverterWarn
=
hygfjpInverterWarnMapper
.
selectOne
(
new
QueryWrapper
<
HYGFJPInverterWarn
>().
eq
(
"sn_code"
,
tanYinAlramInfo
.
getSn
())
.
eq
(
"warn_id"
,
tanYinAlramInfo
.
getId
())
.
eq
(
"third_station_id"
,
String
.
valueOf
(
tanYinAlramInfo
.
getProjectNo
())));
.
eq
(
"third_station_id"
,
String
.
valueOf
(
tanYinAlramInfo
.
getProjectNo
()))
.
orderByDesc
(
"created_time"
).
last
(
"limit 1"
)
);
if
(
com
.
baomidou
.
mybatisplus
.
core
.
toolkit
.
ObjectUtils
.
isEmpty
(
hygfjpInverterWarn
))
{
hygfjpInverterWarn
=
new
HYGFJPInverterWarn
();
}
...
...
@@ -500,7 +515,6 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
hygfjpInverterWarn
.
setRegionalCompaniesCode
(
jpStation
.
getRegionalCompaniesCode
());
hygfjpInverterWarn
.
setStationName
(
jpStation
.
getName
());
hygfjpInverterWarn
.
setStationState
(
jpStation
.
getState
());
hygfjpInverterWarn
.
setCreatedTime
(
System
.
currentTimeMillis
());
hygfjpInverterWarn
.
setThirdCode
(
PVProducerInfoEnum
.
TANYIN
.
getCode
());
hygfjpInverterWarn
.
setContent
(
tanYinAlramInfo
.
getContent
());
hygfjpInverterWarn
.
setTreatment
(
tanYinAlramInfo
.
getSolution
());
...
...
@@ -515,7 +529,7 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
}
hygfjpInverterWarn
.
setTimeLong
(
null
);
if
((!
ObjectUtils
.
isEmpty
(
tanYinAlramInfo
.
getFaultOccurTime
()))
&&
(!
ObjectUtils
.
isEmpty
(
tanYinAlramInfo
.
getFaultEndTime
())))
{
hygfjpInverterWarn
.
setTimeLong
(
this
.
convertDate
(
hygfjpInverterWarn
.
getRecoverTime
())
-
this
.
convertDate
(
hygfjpInverterWarn
.
getStartTime
()));
hygfjpInverterWarn
.
setTimeLong
(
this
.
convertDate
(
hygfjpInverterWarn
.
getRecoverTime
())
-
this
.
convertDate
(
hygfjpInverterWarn
.
getStartTime
()));
}
if
(
ObjectUtils
.
isEmpty
(
hygfjpInverterWarn
.
getCreatedTime
()))
{
hygfjpInverterWarn
.
setCreatedTime
(
System
.
currentTimeMillis
());
...
...
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 @
3a296cd3
...
...
@@ -729,7 +729,7 @@ public class MonitorServiceImpl implements MonitorService {
budunStationValueDtoList
.
forEach
(
budunStationValueDto
->
{
HashMap
<
String
,
String
>
hashMap1
=
new
HashMap
<>();
hashMap1
.
put
(
"stationName"
,
budunStationValueDto
.
getStation_name
());
hashMap1
.
put
(
"value"
,
budunStationValueDto
.
getValue
()
+
"%"
);
hashMap1
.
put
(
"value"
,
(
budunStationValueDto
.
getValue
()
==
null
?
0
:
budunStationValueDto
.
getValue
())
+
"%"
);
hashMap1
.
put
(
"value1"
,
String
.
valueOf
(
budunStationValueDto
.
getValue
()));
mapList
.
add
(
hashMap1
);
});
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-monitor-biz/src/main/resources/application-dev1.properties
View file @
3a296cd3
## DB properties:
## db1-production database
spring.db1.datasource.type
:
com.alibaba.druid.pool.DruidDataSource
spring.db1.datasource.url
=
jdbc:
mysql://10.20.1.157:3306
/production?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db1.datasource.url
=
jdbc:
kingbase8://10.20.1.176:54321
/production?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db1.datasource.username
=
root
spring.db1.datasource.password
=
Yeejoin@2020
spring.db1.datasource.driver-class-name
:
com.mysql.cj.jdbc
.Driver
spring.db1.datasource.driver-class-name
:
com.kingbase8
.Driver
## db2-sync_data
spring.db2.datasource.type
:
com.alibaba.druid.pool.DruidDataSource
spring.db2.datasource.url
=
jdbc:
mysql://10.20.1.157:3306
/jxiop_sync_data?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db2.datasource.url
=
jdbc:
kingbase8://10.20.1.176:54321
/jxiop_sync_data?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db2.datasource.username
=
root
spring.db2.datasource.password
=
Yeejoin@2020
spring.db2.datasource.driver-class-name
:
com.
mysql.cj.jdbc
.Driver
spring.db2.datasource.driver-class-name
:
com.
kingbase8
.Driver
## db4-equip
spring.db4.datasource.type
:
com.alibaba.druid.pool.DruidDataSource
spring.db4.datasource.url
=
jdbc:
mysql://10.20.1.157:3306
/equipment?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db4.datasource.url
=
jdbc:
kingbase8://10.20.1.176:54321
/equipment?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db4.datasource.username
=
root
spring.db4.datasource.password
=
Yeejoin@2020
spring.db4.datasource.driver-class-name
:
com.
mysql.cj.jdbc
.Driver
spring.db4.datasource.driver-class-name
:
com.
kingbase8
.Driver
## db5-amos_project
spring.db5.datasource.type
:
com.alibaba.druid.pool.DruidDataSource
spring.db5.datasource.url
=
jdbc:
mysql://10.20.1.157:3306
/amos_project?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db5.datasource.url
=
jdbc:
kingbase8://10.20.1.176:54321
/amos_project?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.db5.datasource.username
=
root
spring.db5.datasource.password
=
Yeejoin@2020
spring.db5.datasource.driver-class-name
:
com.
mysql.cj.jdbc
.Driver
spring.db5.datasource.driver-class-name
:
com.
kingbase8
.Driver
## db3-td-engine
#spring.db3.datasource.type: com.alibaba.druid.pool.DruidDataSource
spring.db3.datasource.url
=
jdbc:TAOS-RS://10.20.
1.157
:6041/iot_data?user=root&password=taosdata&timezone=GMT%2b8&allowMultiQueries=true
spring.db3.datasource.url
=
jdbc:TAOS-RS://10.20.
0.203
:6041/iot_data?user=root&password=taosdata&timezone=GMT%2b8&allowMultiQueries=true
spring.db3.datasource.username
=
root
spring.db3.datasource.password
=
taosdata
spring.db3.datasource.driver-class-name
:
com.taosdata.jdbc.rs.RestfulDriver
...
...
@@ -74,10 +74,10 @@ lettuce.timeout=10000
emqx.clean-session
=
true
emqx.client-id
=
${spring.application.name}-${random.int[1024,65536]}
emqx.broker
=
tcp://
47.92.234.253:1
883
emqx.broker
=
tcp://
10.20.1.210:2
883
emqx.user-name
=
admin
emqx.password
=
public
mqtt.scene.host
=
mqtt://
47.92.234.253:1
8083/mqtt
mqtt.scene.host
=
mqtt://
10.20.1.210:
8083/mqtt
mqtt.client.product.id
=
mqtt
mqtt.topic
=
topic_mqtt
spring.mqtt.completionTimeout
=
3000
...
...
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