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
69d4e8d0
Commit
69d4e8d0
authored
Jul 11, 2024
by
hezhuozhi
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/developer' into developer
parents
b955c4ef
db8f2197
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
99 additions
and
47 deletions
+99
-47
PowerStationEngineeringInfo.java
...t/module/hygf/api/entity/PowerStationEngineeringInfo.java
+2
-1
PreparationMoney.java
...in/amos/boot/module/hygf/api/entity/PreparationMoney.java
+2
-1
PeasantHouseholdMapper.java
...s/boot/module/hygf/api/mapper/PeasantHouseholdMapper.java
+2
-1
PeasantHouseholdMapper.xml
...rc/main/resources/mapper/mysql/PeasantHouseholdMapper.xml
+3
-1
PreparationMoneyMapper.xml
...rc/main/resources/mapper/mysql/PreparationMoneyMapper.xml
+8
-2
WorkOrderMapper.xml
...f-api/src/main/resources/mapper/mysql/WorkOrderMapper.xml
+1
-1
UnitInfoController.java
...s/boot/module/hygf/biz/controller/UnitInfoController.java
+17
-1
BasicGridAcceptanceServiceImpl.java
...hygf/biz/service/impl/BasicGridAcceptanceServiceImpl.java
+5
-8
PeasantHouseholdServiceImpl.java
...le/hygf/biz/service/impl/PeasantHouseholdServiceImpl.java
+1
-4
PersonnelBusinessServiceImpl.java
...e/hygf/biz/service/impl/PersonnelBusinessServiceImpl.java
+2
-2
PreparationMoneyServiceImpl.java
...le/hygf/biz/service/impl/PreparationMoneyServiceImpl.java
+1
-0
UnitInfoServiceImpl.java
...oot/module/hygf/biz/service/impl/UnitInfoServiceImpl.java
+19
-2
WorkOrderServiceImpl.java
...ot/module/hygf/biz/service/impl/WorkOrderServiceImpl.java
+9
-1
application.properties
...iop-analyse-biz/src/main/resources/application.properties
+1
-1
Region.java
...com/yeejoin/amos/boot/module/jxiop/api/entity/Region.java
+1
-1
LargeScreenImpl.java
...s/boot/module/jxiop/biz/service/impl/LargeScreenImpl.java
+20
-18
MonitoringServiceImpl.java
.../module/jxiop/biz/service/impl/MonitoringServiceImpl.java
+2
-1
SjglZsjZsbtzMapper.xml
.../src/main/resources/mapper/cluster/SjglZsjZsbtzMapper.xml
+3
-1
No files found.
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/entity/PowerStationEngineeringInfo.java
View file @
69d4e8d0
package
com
.
yeejoin
.
amos
.
boot
.
module
.
hygf
.
api
.
entity
;
import
com.baomidou.mybatisplus.annotation.FieldStrategy
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
...
...
@@ -104,7 +105,7 @@ public class PowerStationEngineeringInfo extends BaseEntity {
private
Long
workOrderPowerStationId
;
@TableField
(
"completion_date"
)
@TableField
(
value
=
"completion_date"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
Date
completionDate
;
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/entity/PreparationMoney.java
View file @
69d4e8d0
package
com
.
yeejoin
.
amos
.
boot
.
module
.
hygf
.
api
.
entity
;
import
com.baomidou.mybatisplus.annotation.FieldStrategy
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler
;
...
...
@@ -115,7 +116,7 @@ public class PreparationMoney extends BaseEntity {
/**
* 发货时间
*/
@TableField
(
"delivery_time"
)
@TableField
(
value
=
"delivery_time"
,
updateStrategy
=
FieldStrategy
.
IGNORED
)
private
Date
deliveryTime
;
/**
* 到货时间
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/java/com/yeejoin/amos/boot/module/hygf/api/mapper/PeasantHouseholdMapper.java
View file @
69d4e8d0
...
...
@@ -19,7 +19,8 @@ public interface PeasantHouseholdMapper extends BaseMapper<PeasantHousehold> {
@Param
(
"regionalCompaniesSeq"
)
Long
regionalCompaniesSeq
,
@Param
(
"peasantHouseholdNo"
)
String
peasantHouseholdNo
,
@Param
(
"ownersName"
)
String
ownersName
,
@Param
(
"ids"
)
String
ids
@Param
(
"ids"
)
String
ids
,
@Param
(
"orderBy"
)
String
orderBy
);
List
<
PeasantHousehold
>
selectPeasantHouseholdListsg
(
@Param
(
"unitInfoCode"
)
String
unitInfoCode
,
@Param
(
"regionalCompaniesSeq"
)
Long
regionalCompaniesSeq
,
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/resources/mapper/mysql/PeasantHouseholdMapper.xml
View file @
69d4e8d0
...
...
@@ -22,7 +22,9 @@ on hygf_document_station.preparation_money_id=hygf_preparation_money.sequence_nb
<if
test=
"ownersName!=null and ownersName !='' "
>
and hygf_peasant_household.owners_name like concat(concat("%",#{ownersName}),"%")
</if>
<if
test=
"orderBy !=null and orderBy !='' "
>
ORDER BY ${orderBy}
</if>
</select>
<select
id=
"selectPeasantHouseholdListsg"
resultType=
"com.yeejoin.amos.boot.module.hygf.api.entity.PeasantHousehold"
>
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/resources/mapper/mysql/PreparationMoneyMapper.xml
View file @
69d4e8d0
...
...
@@ -37,7 +37,7 @@ LEFT JOIN hygf_document_station on hygf_document_station.station_id=hygf_peasan
and hygf_preparation_money.delivery_time between #{dto.deliveryTimeStart} and #{dto.deliveryTimeEnd}
</if>
</where>
ORDER BY
rec_date
DESC
ORDER BY
hygf_preparation_money.sequence_nbr
DESC
</select>
<select
id=
"preparationStation"
resultType=
"java.util.Map"
>
...
...
@@ -82,7 +82,13 @@ LEFT JOIN hygf_document_station on hygf_document_station.station_id=hygf_peasan
</if>
</where>
GROUP BY hygf_peasant_household.sequence_nbr
order by hygf_peasant_household.sequence_nbr DESC ) b
<if
test=
" preparationMoneyState == 1 "
>
order by hygf_preparation_money.delivery_time DESC
</if>
<if
test=
" preparationMoneyState == 0 "
>
order by hygf_peasant_household.sequence_nbr DESC
</if>
) b
</select>
</mapper>
amos-boot-system-jxiop/amos-boot-module-hygf-api/src/main/resources/mapper/mysql/WorkOrderMapper.xml
View file @
69d4e8d0
...
...
@@ -110,7 +110,7 @@
</if>
ORDER BY
hygf_
power_station_engineering_info.completion
_date DESC,
hygf_
work_order.rec
_date DESC,
FIELD(hygf_work_order_power_station.power_station_construction_status, '待施工', '施工中', '待登记', '登记中', '待审核', '审核中', '未通过', '已完工')
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/controller/UnitInfoController.java
View file @
69d4e8d0
...
...
@@ -775,7 +775,7 @@ public class UnitInfoController extends BaseController {
@RequestParam
(
required
=
false
)
Long
regionalCompaniesSeq
)
{
UnitInfo
unitInfo
=
unitInfoMapper
.
selectById
(
unitInfoId
);
List
<
PeasantHousehold
>
list
=
peasantHouseholdMapper
.
selectPeasantHouseholdList
(
unitInfo
.
getAmosCompanySeq
(),
regionalCompaniesSeq
,
null
,
null
,
null
);
List
<
PeasantHousehold
>
list
=
peasantHouseholdMapper
.
selectPeasantHouseholdList
(
unitInfo
.
getAmosCompanySeq
(),
regionalCompaniesSeq
,
null
,
null
,
null
,
null
);
List
<
Map
<
String
,
Object
>>
date
=
new
ArrayList
<>();
if
(
list
!=
null
){
...
...
@@ -806,6 +806,22 @@ public class UnitInfoController extends BaseController {
return
ResponseHelper
.
buildResponse
(
unitInfoServiceImpl
.
getPeasantHouseholdData
(
unitInfoId
,
regionalCompaniesSeq
,
current
,
size
,
peasantHouseholdNo
,
ownersName
,
ids
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"列表全部数据查询"
,
notes
=
"列表全部数据查询"
)
@GetMapping
(
value
=
"/getPeasantHouseholdDataNew"
)
public
ResponseModel
<
Page
<
PeasantHousehold
>>
getPeasantHouseholdDataNew
(
@RequestParam
(
required
=
false
)
Long
unitInfoId
,
@RequestParam
(
required
=
false
)
Long
regionalCompaniesSeq
,
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
required
=
false
)
String
peasantHouseholdNo
,
@RequestParam
(
required
=
false
)
String
ownersName
,
@RequestParam
(
required
=
false
)
String
ids
)
{
return
ResponseHelper
.
buildResponse
(
unitInfoServiceImpl
.
getPeasantHouseholdDataNew
(
unitInfoId
,
regionalCompaniesSeq
,
current
,
size
,
peasantHouseholdNo
,
ownersName
,
ids
));
}
/**获取当前登录人区域公司*/
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/BasicGridAcceptanceServiceImpl.java
View file @
69d4e8d0
...
...
@@ -87,18 +87,15 @@ public class BasicGridAcceptanceServiceImpl
return
pageNew
;
}
public
HygfOnGrid
saveEntity
(
HygfOnGrid
grid
)
{
if
(
grid
.
getSequenceNbr
()
!=
null
)
{
onGridMapper
.
updateById
(
grid
);
}
else
{
onGridMapper
.
insert
(
grid
);
}
public
synchronized
HygfOnGrid
saveEntity
(
HygfOnGrid
grid
)
{
LambdaQueryWrapper
<
HygfOnGrid
>
hog
=
new
LambdaQueryWrapper
<>();
hog
.
eq
(
HygfOnGrid:
:
getPeasantHouseholdId
,
grid
.
getPeasantHouseholdId
());
hygfOnGridServiceImpl
.
saveOrUpdate
(
grid
,
hog
);
return
grid
;
}
@GlobalTransactional
public
HygfOnGrid
saveAndCommit
(
HygfOnGrid
grid
,
String
userId
)
{
public
synchronized
HygfOnGrid
saveAndCommit
(
HygfOnGrid
grid
,
String
userId
)
{
BasicGridAcceptance
basicGridAcceptance
=
basicGridAcceptanceMapper
.
selectOne
(
new
LambdaQueryWrapper
<
BasicGridAcceptance
>()
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/PeasantHouseholdServiceImpl.java
View file @
69d4e8d0
...
...
@@ -867,16 +867,13 @@ public class PeasantHouseholdServiceImpl extends BaseService<PeasantHouseholdDto
model
.
setSurveyInformationId
(
surveyInformationDto
.
getSequenceNbr
());
model
.
setSurveyOrNot
(
0
);
model
.
setReview
(
0
);
if
(
model
.
getCreationTime
()
==
null
)
{
model
.
setCreationTime
(
new
Date
());
}
model
.
setPeasantHouseholdNo
(
this
.
getPeasantHouseholdNo
(
model
.
getRegionalCompaniesSeq
()));
model
.
setIsCertified
(
model
.
getIsCertified
()
==
null
?
0
:
model
.
getIsCertified
());
// 未认证
PeasantHousehold
peasantHousehold
=
new
PeasantHousehold
();
BeanUtils
.
copyProperties
(
model
,
peasantHousehold
);
peasantHousehold
.
setSequenceNbr
(
null
);
peasantHousehold
.
setRecDat
e
(
new
Date
());
model
.
setCreationTim
e
(
new
Date
());
peasantHousehold
.
setConstructionState
(
ArrivalStateeEnum
.
待勘察
.
getCode
());
this
.
save
(
peasantHousehold
);
//生成合同
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/PersonnelBusinessServiceImpl.java
View file @
69d4e8d0
...
...
@@ -509,8 +509,8 @@ public class PersonnelBusinessServiceImpl extends BaseService<PersonnelBusinessD
userDataJBDto
.
setPageType
(
"look"
);
if
(
publicAgencyUse
.
getRole
().
contains
(
userGroupempty
+
""
))
{
// 如果是空角色,区域公司和角色可以修改
userDataZHDto
.
setUnallowModify
(
"
un
allow"
);
userDataJBDto
.
setUnallowModify
(
"
un
allow"
);
userDataZHDto
.
setUnallowModify
(
"allow"
);
userDataJBDto
.
setUnallowModify
(
"allow"
);
}
else
{
// 有业务参与不可以编辑
userDataZHDto
.
setUnallowModify
(
hasOperationRecords
?
"unallow"
:
"allow"
);
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/PreparationMoneyServiceImpl.java
View file @
69d4e8d0
...
...
@@ -1086,6 +1086,7 @@ public class PreparationMoneyServiceImpl extends BaseService<PreparationMoneyDto
up
.
set
(
PeasantHousehold:
:
getPreparationMoneyState
,
DeliveryStateeEnum
.
待补货
.
getName
());
up
.
set
(
PeasantHousehold:
:
getConstructionState
,
DeliveryStateeEnum
.
待补货
.
getName
());
up
.
in
(
BaseEntity:
:
getSequenceNbr
,
collect
);
preparationMoney
.
setDeliveryTime
(
null
);
peasantHouseholdMapper
.
update
(
null
,
up
);
}
else
{
preparationMoney
.
setOrderStatus
(
DeliveryStateeEnum
.
待确认
.
getName
());
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/UnitInfoServiceImpl.java
View file @
69d4e8d0
...
...
@@ -1034,7 +1034,24 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto,UnitInfo,UnitIn
return
jsonArray
;
}
public
Page
<
PeasantHousehold
>
getPeasantHouseholdDataNew
(
Long
unitInfoId
,
Long
regionalCompaniesSeq
,
int
pageNum
,
int
pageSize
,
String
peasantHouseholdNo
,
String
ownersName
,
String
ids
)
{
UnitInfo
unitInfo
=
unitInfoMapper
.
selectById
(
unitInfoId
);
PageHelper
.
startPage
(
pageNum
,
pageSize
);
List
<
PeasantHousehold
>
list
=
peasantHouseholdMapper
.
selectPeasantHouseholdList
(
unitInfo
.
getAmosCompanySeq
(),
regionalCompaniesSeq
,
peasantHouseholdNo
,
ownersName
,
ids
,
"hygf_peasant_household.rec_date DESC"
);
PageInfo
<
PeasantHousehold
>
page
=
new
PageInfo
(
list
);
Page
<
PeasantHousehold
>
pagenew
=
new
Page
<
PeasantHousehold
>();
pagenew
.
setCurrent
(
pageNum
);
pagenew
.
setTotal
(
page
.
getTotal
());
pagenew
.
setSize
(
pageSize
);
pagenew
.
setRecords
(
page
.
getList
());
return
pagenew
;
}
public
Page
<
PeasantHousehold
>
getPeasantHouseholdData
(
Long
unitInfoId
,
Long
regionalCompaniesSeq
,
...
...
@@ -1045,7 +1062,7 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto,UnitInfo,UnitIn
String
ids
){
UnitInfo
unitInfo
=
unitInfoMapper
.
selectById
(
unitInfoId
);
PageHelper
.
startPage
(
pageNum
,
pageSize
);
List
<
PeasantHousehold
>
list
=
peasantHouseholdMapper
.
selectPeasantHouseholdList
(
unitInfo
.
getAmosCompanySeq
(),
regionalCompaniesSeq
,
peasantHouseholdNo
,
ownersName
,
ids
);
List
<
PeasantHousehold
>
list
=
peasantHouseholdMapper
.
selectPeasantHouseholdList
(
unitInfo
.
getAmosCompanySeq
(),
regionalCompaniesSeq
,
peasantHouseholdNo
,
ownersName
,
ids
,
null
);
PageInfo
<
PeasantHousehold
>
page
=
new
PageInfo
(
list
);
Page
<
PeasantHousehold
>
pagenew
=
new
Page
<
PeasantHousehold
>();
pagenew
.
setCurrent
(
pageNum
);
...
...
amos-boot-system-jxiop/amos-boot-module-hygf-biz/src/main/java/com/yeejoin/amos/boot/module/hygf/biz/service/impl/WorkOrderServiceImpl.java
View file @
69d4e8d0
...
...
@@ -339,6 +339,7 @@ public class WorkOrderServiceImpl extends BaseService<WorkOrderDto, WorkOrder, W
LambdaUpdateWrapper
<
ConstructionRecords
>
pcr
=
new
LambdaUpdateWrapper
<>();
pcr
.
eq
(
ConstructionRecords:
:
getWorkOrderId
,
powerStationConstructionData
.
getWorkOrderId
());
pcr
.
eq
(
ConstructionRecords:
:
getWorkOrderPowerStationId
,
powerStationConstructionData
.
getWorkOrderPowerStationId
());
pcr
.
eq
(
ConstructionRecords:
:
getOperationContent
,
"新增施工资料"
);
// 自审不通过,重新上传的时候不要覆盖之前的数据
constructionRecordsServiceImpl
.
saveOrUpdate
(
da
,
pcr
);
}
else
{
...
...
@@ -886,7 +887,7 @@ public class WorkOrderServiceImpl extends BaseService<WorkOrderDto, WorkOrder, W
// 防止重复提交
LambdaQueryWrapper
<
PowerStationEngineeringInfo
>
pse
=
new
LambdaQueryWrapper
<>();
pse
.
eq
(
PowerStationEngineeringInfo:
:
getWorkOrderId
,
powerStationEngineeringInfo
.
getWorkOrderId
());
//
pse.eq(PowerStationEngineeringInfo::getWorkOrderPowerStationId,powerStationEngineeringInfo.getWorkOrderPowerStationId());
pse
.
eq
(
PowerStationEngineeringInfo:
:
getWorkOrderPowerStationId
,
powerStationEngineeringInfo
.
getWorkOrderPowerStationId
());
// powerStationEngineeringInfoService.saveOrUpdate(powerStationEngineeringInfo);
powerStationEngineeringInfoService
.
saveOrUpdate
(
powerStationEngineeringInfo
,
pse
);
// 增加操作日志
...
...
@@ -979,6 +980,13 @@ public class WorkOrderServiceImpl extends BaseService<WorkOrderDto, WorkOrder, W
upq
.
set
(
WorkOrder:
:
getWorkOrderStatus
,
WorkOrderEnum
.
未通过
.
getCode
());
workOrderMapper
.
update
(
null
,
upq
);
// 修改完工时间
LambdaUpdateWrapper
<
PowerStationEngineeringInfo
>
upq1
=
new
LambdaUpdateWrapper
();
upq1
.
eq
(
PowerStationEngineeringInfo:
:
getWorkOrderPowerStationId
,
workOrderPowerStation
.
getSequenceNbr
());
upq1
.
set
(
PowerStationEngineeringInfo:
:
getCompletionDate
,
null
);
powerStationEngineeringInfoMapper
.
update
(
null
,
upq1
);
}
// 增加操作日志
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-analyse-biz/src/main/resources/application.properties
View file @
69d4e8d0
spring.application.name
=
AMOS-JXIOP-ANALYSE-
WJ
spring.application.name
=
AMOS-JXIOP-ANALYSE-
CZ
server.servlet.context-path
=
/jxiop-analyse
server.port
=
33400
server.uri-encoding
=
UTF-8
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-api/src/main/java/com/yeejoin/amos/boot/module/jxiop/api/entity/Region.java
View file @
69d4e8d0
...
...
@@ -34,7 +34,7 @@ public class Region {
/**
* 等级
*/
@TableField
(
"LEVEL"
)
@TableField
(
"LEVEL
_
"
)
private
String
level
;
/**
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-bigscreen-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/service/impl/LargeScreenImpl.java
View file @
69d4e8d0
...
...
@@ -135,18 +135,19 @@ public class LargeScreenImpl {
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_quota_info
;
LocalDate
currentDate
=
LocalDate
.
now
();
DateTimeFormatter
formatter
=
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
);
String
formattedDate
=
currentDate
.
format
(
formatter
);
LocalDate
yesterday
=
currentDate
.
minusDays
(
1
);
String
formattedDate
=
yesterday
.
format
(
formatter
);
JSONObject
data
=
httpRequestUtil
.
getResPonse
(
requestUrl
+
"&reporting_data="
+
formattedDate
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
);
if
(
data
!=
null
)
{
// 部盾每天十二点才填报,如果十二点前没有数据则获取前一天的数据
if
(
data
.
getDouble
(
"sum_irradiance"
)
!=
null
&&
data
.
getDouble
(
"sum_irradiance"
)
==
0
)
{
// 计算昨天日期
LocalDate
yesterday
=
currentDate
.
minusDays
(
1
);
formattedDate
=
yesterday
.
format
(
formatter
);
data
=
httpRequestUtil
.
getResPonse
(
requestUrl
+
"&reporting_data="
+
formattedDate
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
);
}
//
// 部盾每天十二点才填报,如果十二点前没有数据则获取前一天的数据
//
if (data.getDouble("sum_irradiance") != null && data.getDouble("sum_irradiance") == 0) {
//
// 计算昨天日期
//
LocalDate yesterday = currentDate.minusDays(1);
//
formattedDate = yesterday.format(formatter);
//
data = httpRequestUtil.getResPonse(requestUrl + "&reporting_data=" + formattedDate,
//
Constants.REQUEST_GET, "", Constants.resovleRule_data);
//
}
mapdta
.
put
(
"SS"
,
data
.
getDouble
(
"average_wind_speed"
));
mapdta
.
put
(
"ZFS"
,
data
.
getDouble
(
"avg_irradiance"
));
mapdta
.
put
(
"ZFSLJ"
,
data
.
getDouble
(
"sum_irradiance"
));
...
...
@@ -243,7 +244,7 @@ public class LargeScreenImpl {
}
@Scheduled
(
cron
=
"0/10 * * * * ?"
)
@PostConstruct
//
@PostConstruct
private
void
sendQYYXZBMqtt
()
{
List
<
StationCacheInfoDto
>
listStationCacheInfoDto
=
commonServiceImpl
.
getListStationCacheInfoDto
();
Map
<
String
,
List
<
StationCacheInfoDto
>>
belongAreaList
=
listStationCacheInfoDto
.
stream
()
...
...
@@ -406,7 +407,8 @@ public class LargeScreenImpl {
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_quota_info
;
LocalDate
currentDate
=
LocalDate
.
now
();
DateTimeFormatter
formatter
=
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
);
String
formattedDate
=
currentDate
.
format
(
formatter
);
LocalDate
yesterday
=
currentDate
.
minusDays
(
1
);
String
formattedDate
=
yesterday
.
format
(
formatter
);
JSONObject
data
=
httpRequestUtil
.
getResPonse
(
requestUrl
+
"&reporting_data="
+
formattedDate
+
"&code="
+
s
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
);
DecimalFormat
df
=
new
DecimalFormat
(
"#.0000"
);
...
...
@@ -430,13 +432,13 @@ public class LargeScreenImpl {
}
// 部盾每天十二点才填报,如果十二点前没有数据则获取前一天的数据
if
(
data
.
getDouble
(
"sum_irradiance"
)
!=
null
&&
data
.
getDouble
(
"sum_irradiance"
)
==
0
)
{
// 计算昨天日期
LocalDate
yesterday
=
currentDate
.
minusDays
(
1
);
formattedDate
=
yesterday
.
format
(
formatter
);
data
=
httpRequestUtil
.
getResPonse
(
requestUrl
+
"&reporting_data="
+
formattedDate
+
"&code="
+
s
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
);
}
//
if (data.getDouble("sum_irradiance") != null && data.getDouble("sum_irradiance") == 0) {
//
// 计算昨天日期
//
LocalDate yesterday = currentDate.minusDays(1);
//
formattedDate = yesterday.format(formatter);
//
data = httpRequestUtil.getResPonse(requestUrl + "&reporting_data=" + formattedDate+"&code="+s, Constants.REQUEST_GET,
//
"", Constants.resovleRule_data);
//
}
mapdta
.
put
(
"SS"
,
data
.
getString
(
"average_wind_speed"
));
mapdta
.
put
(
"ZFS"
,
data
.
getString
(
"avg_irradiance"
));
mapdta
.
put
(
"ZFSLJ"
,
data
.
getString
(
"sum_irradiance"
));
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-bigscreen-biz/src/main/java/com/yeejoin/amos/boot/module/jxiop/biz/service/impl/MonitoringServiceImpl.java
View file @
69d4e8d0
...
...
@@ -1110,7 +1110,8 @@ public class MonitoringServiceImpl {
String
requestUrl
=
Constants
.
BASE_URL
+
"?"
+
Constants
.
get_quota_info
;
LocalDate
currentDate
=
LocalDate
.
now
();
DateTimeFormatter
formatter
=
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
);
String
formattedDate
=
currentDate
.
format
(
formatter
);
LocalDate
yesterday
=
currentDate
.
minusDays
(
1
);
String
formattedDate
=
yesterday
.
format
(
formatter
);
JSONObject
data
=
httpRequestUtil
.
getResPonse
(
requestUrl
+
"&reporting_data="
+
formattedDate
,
Constants
.
REQUEST_GET
,
""
,
Constants
.
resovleRule_data
);
DecimalFormat
df
=
new
DecimalFormat
(
"#.0000"
);
...
...
amos-boot-system-jxiop/amos-boot-module-jxiop-bigscreen-biz/src/main/resources/mapper/cluster/SjglZsjZsbtzMapper.xml
View file @
69d4e8d0
...
...
@@ -2,7 +2,9 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.boot.module.jxiop.biz.mapper2.SjglZsjZsbtzMapper"
>
<select
id=
"getStationCapactityByStationWerks"
resultType=
"Double"
>
select SUM(IFNULL(trim(CAPACITYL),0)) from sjgl_zsj_zsbtz where WERKS = #{WERKS}
SELECT SUM(CASE WHEN TRIM(CAPACITYL) IS NULL OR TRIM(CAPACITYL) = '' THEN 0 ELSE CAST(TRIM(CAPACITYL) AS DECIMAL(10, 2)) END)
FROM sjgl_zsj_zsbtz
WHERE WERKS =#{WERKS}
</select>
<select
id=
"getStationInfoMapByStationWerks"
resultType=
"map"
>
...
...
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