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
acca8a3e
Commit
acca8a3e
authored
Aug 02, 2024
by
lilongyang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' of
http://36.40.66.175:5000/moa/jxdj_zx/amos-boot-zx-biz
into developer
parents
e778e8b3
3a296cd3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
14 deletions
+28
-14
TanYinDataAcquisitionServiceImpl.java
...i/face/service/impl/TanYinDataAcquisitionServiceImpl.java
+21
-7
SjglZsjZsbtzMapper.xml
.../src/main/resources/mapper/cluster/SjglZsjZsbtzMapper.xml
+7
-7
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 @
acca8a3e
...
@@ -178,7 +178,7 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
...
@@ -178,7 +178,7 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
@Override
@Override
public
void
customerInfoList
()
{
public
void
customerInfoList
()
{
try
{
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"
));
String
endDate
=
LocalDate
.
now
().
plusDays
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
log
.
info
(
"-------碳银同步项目信息开始: {} ------- "
,
sdf
.
format
(
new
Date
()));
log
.
info
(
"-------碳银同步项目信息开始: {} ------- "
,
sdf
.
format
(
new
Date
()));
Map
<
String
,
Object
>
params
=
MapBuilder
.<
String
,
Object
>
create
()
Map
<
String
,
Object
>
params
=
MapBuilder
.<
String
,
Object
>
create
()
...
@@ -465,7 +465,12 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
...
@@ -465,7 +465,12 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
if
(
jpInverter
==
null
||
StringUtils
.
isEmpty
(
jpInverter
.
getSnCode
()))
{
if
(
jpInverter
==
null
||
StringUtils
.
isEmpty
(
jpInverter
.
getSnCode
()))
{
return
;
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"
));
String
endDate
=
LocalDate
.
now
().
plusDays
(
1
).
format
(
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
));
Map
<
String
,
Object
>
params
=
MapBuilder
.<
String
,
Object
>
create
()
Map
<
String
,
Object
>
params
=
MapBuilder
.<
String
,
Object
>
create
()
.
put
(
"sn"
,
jpInverter
.
getSnCode
())
.
put
(
"sn"
,
jpInverter
.
getSnCode
())
...
@@ -474,11 +479,19 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
...
@@ -474,11 +479,19 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
.
put
(
"startDate"
,
startDate
)
.
put
(
"startDate"
,
startDate
)
.
put
(
"endDate"
,
endDate
).
build
();
.
put
(
"endDate"
,
endDate
).
build
();
PageInfo
<
TanYinAlramInfo
>
tanYinInveterInfo
=
tanYinApiUtils
.
postPage
(
"电站逆变器故障信息"
,
apiUrl
+
TanYinConstant
.
inverterAlramUrl
,
JSON
.
toJSONString
(
params
),
null
,
TanYinAlramInfo
.
class
);
PageInfo
<
TanYinAlramInfo
>
tanYinInveterInfo
=
tanYinApiUtils
.
postPage
(
"电站逆变器故障信息"
,
apiUrl
+
TanYinConstant
.
inverterAlramUrl
,
JSON
.
toJSONString
(
params
),
null
,
TanYinAlramInfo
.
class
);
List
<
TanYinAlramInfo
>
tanYinAlramInfos
=
tanYinInveterInfo
.
getList
();
if
(
tanYinInveterInfo
==
null
||
CollectionUtils
.
isEmpty
(
tanYinInveterInfo
.
getList
()))
{
if
(
CollectionUtils
.
isEmpty
(
tanYinAlramInfos
))
{
log
.
warn
(
"-------碳银同步电站逆变器故障信息结束: 未获取到逆变器故障信息 ------- "
);
log
.
warn
(
"-------碳银同步电站逆变器故障信息结束: 未获取到逆变器故障信息 ------- "
);
return
;
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
)
{
for
(
TanYinAlramInfo
tanYinAlramInfo
:
tanYinAlramInfos
)
{
tanYinAlramInfo
.
setCreateTime
(
System
.
currentTimeMillis
());
tanYinAlramInfo
.
setCreateTime
(
System
.
currentTimeMillis
());
tanYinAlramInfoMapper
.
insert
(
tanYinAlramInfo
);
tanYinAlramInfoMapper
.
insert
(
tanYinAlramInfo
);
...
@@ -486,7 +499,9 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
...
@@ -486,7 +499,9 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
HYGFJPInverterWarn
hygfjpInverterWarn
=
hygfjpInverterWarnMapper
HYGFJPInverterWarn
hygfjpInverterWarn
=
hygfjpInverterWarnMapper
.
selectOne
(
new
QueryWrapper
<
HYGFJPInverterWarn
>().
eq
(
"sn_code"
,
tanYinAlramInfo
.
getSn
())
.
selectOne
(
new
QueryWrapper
<
HYGFJPInverterWarn
>().
eq
(
"sn_code"
,
tanYinAlramInfo
.
getSn
())
.
eq
(
"warn_id"
,
tanYinAlramInfo
.
getId
())
.
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
))
{
if
(
com
.
baomidou
.
mybatisplus
.
core
.
toolkit
.
ObjectUtils
.
isEmpty
(
hygfjpInverterWarn
))
{
hygfjpInverterWarn
=
new
HYGFJPInverterWarn
();
hygfjpInverterWarn
=
new
HYGFJPInverterWarn
();
}
}
...
@@ -500,7 +515,6 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
...
@@ -500,7 +515,6 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
hygfjpInverterWarn
.
setRegionalCompaniesCode
(
jpStation
.
getRegionalCompaniesCode
());
hygfjpInverterWarn
.
setRegionalCompaniesCode
(
jpStation
.
getRegionalCompaniesCode
());
hygfjpInverterWarn
.
setStationName
(
jpStation
.
getName
());
hygfjpInverterWarn
.
setStationName
(
jpStation
.
getName
());
hygfjpInverterWarn
.
setStationState
(
jpStation
.
getState
());
hygfjpInverterWarn
.
setStationState
(
jpStation
.
getState
());
hygfjpInverterWarn
.
setCreatedTime
(
System
.
currentTimeMillis
());
hygfjpInverterWarn
.
setThirdCode
(
PVProducerInfoEnum
.
TANYIN
.
getCode
());
hygfjpInverterWarn
.
setThirdCode
(
PVProducerInfoEnum
.
TANYIN
.
getCode
());
hygfjpInverterWarn
.
setContent
(
tanYinAlramInfo
.
getContent
());
hygfjpInverterWarn
.
setContent
(
tanYinAlramInfo
.
getContent
());
hygfjpInverterWarn
.
setTreatment
(
tanYinAlramInfo
.
getSolution
());
hygfjpInverterWarn
.
setTreatment
(
tanYinAlramInfo
.
getSolution
());
...
@@ -515,7 +529,7 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
...
@@ -515,7 +529,7 @@ public class TanYinDataAcquisitionServiceImpl implements TanYinDataAcquisitionSe
}
}
hygfjpInverterWarn
.
setTimeLong
(
null
);
hygfjpInverterWarn
.
setTimeLong
(
null
);
if
((!
ObjectUtils
.
isEmpty
(
tanYinAlramInfo
.
getFaultOccurTime
()))
&&
(!
ObjectUtils
.
isEmpty
(
tanYinAlramInfo
.
getFaultEndTime
())))
{
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
()))
{
if
(
ObjectUtils
.
isEmpty
(
hygfjpInverterWarn
.
getCreatedTime
()))
{
hygfjpInverterWarn
.
setCreatedTime
(
System
.
currentTimeMillis
());
hygfjpInverterWarn
.
setCreatedTime
(
System
.
currentTimeMillis
());
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-bigscreen-biz/src/main/resources/mapper/cluster/SjglZsjZsbtzMapper.xml
View file @
acca8a3e
...
@@ -73,7 +73,7 @@
...
@@ -73,7 +73,7 @@
count( 1 ) as value
count( 1 ) as value
FROM
FROM
sjgl_zsj_zsbtz a
sjgl_zsj_zsbtz a
INNER
JOIN privilege_company b on a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
LEFT
JOIN privilege_company b on a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
<where>
<where>
<if
test=
"parentCode != null and parentCode != ''"
>
<if
test=
"parentCode != null and parentCode != ''"
>
b.ORG_CODE like concat(#{parentCode},'%')
b.ORG_CODE like concat(#{parentCode},'%')
...
@@ -89,7 +89,7 @@
...
@@ -89,7 +89,7 @@
count(1) as value
count(1) as value
FROM
FROM
fdgl_job_main a
fdgl_job_main a
INNER
JOIN privilege_company b on a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
LEFT
JOIN privilege_company b on a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
<where>
<where>
<if
test=
"parentCode != null and parentCode != ''"
>
<if
test=
"parentCode != null and parentCode != ''"
>
b.ORG_CODE like concat(#{parentCode},'%')
b.ORG_CODE like concat(#{parentCode},'%')
...
@@ -110,7 +110,7 @@
...
@@ -110,7 +110,7 @@
else 3 end) as sort
else 3 end) as sort
FROM
FROM
sjgl_zsj_zsbtz a
sjgl_zsj_zsbtz a
INNER
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
LEFT
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
<where>
<where>
<if
test=
"parentCode != null and parentCode != ''"
>
<if
test=
"parentCode != null and parentCode != ''"
>
AND b.ORG_CODE like concat(#{parentCode},'%')
AND b.ORG_CODE like concat(#{parentCode},'%')
...
@@ -122,9 +122,9 @@
...
@@ -122,9 +122,9 @@
AND a.QRCODE_COLOR = #{qrCodeColor}
AND a.QRCODE_COLOR = #{qrCodeColor}
</if>
</if>
<if
test=
"ne != null and ne != ''"
>
<if
test=
"ne != null and ne != ''"
>
AND a.QRCODE_COLOR != #{ne}
</if>
</if>
</where>
</where>
AND a.QRCODE_COLOR != #{ne}
ORDER BY sort asc, a.UPDATE_STAMP DESC
ORDER BY sort asc, a.UPDATE_STAMP DESC
limit #{current},#{size}
limit #{current},#{size}
</select>
</select>
...
@@ -134,7 +134,7 @@
...
@@ -134,7 +134,7 @@
count(1)
count(1)
FROM
FROM
sjgl_zsj_zsbtz a
sjgl_zsj_zsbtz a
INNER
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
LEFT
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
<where>
<where>
<if
test=
"parentCode != null and parentCode != ''"
>
<if
test=
"parentCode != null and parentCode != ''"
>
AND b.ORG_CODE like concat(#{parentCode},'%')
AND b.ORG_CODE like concat(#{parentCode},'%')
...
@@ -165,7 +165,7 @@
...
@@ -165,7 +165,7 @@
else 3 end as sort
else 3 end as sort
FROM
FROM
fdgl_job_main a
fdgl_job_main a
INNER
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
LEFT
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
left join sjgl_zsj_zsbtz c on a.EQUIP_DBID = c.DBID
left join sjgl_zsj_zsbtz c on a.EQUIP_DBID = c.DBID
<where>
<where>
<if
test=
"parentCode != null and parentCode != ''"
>
<if
test=
"parentCode != null and parentCode != ''"
>
...
@@ -190,7 +190,7 @@
...
@@ -190,7 +190,7 @@
count(1)
count(1)
FROM
FROM
fdgl_job_main a
fdgl_job_main a
INNER
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
LEFT
JOIN privilege_company b ON a.WERKS = b.COMPANY_CODE and b.IS_DELETED = false AND b.`LEVEL` = 'station'
<where>
<where>
<if
test=
"parentCode != null and parentCode != ''"
>
<if
test=
"parentCode != null and parentCode != ''"
>
AND b.ORG_CODE like concat(#{parentCode},'%')
AND b.ORG_CODE like concat(#{parentCode},'%')
...
...
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