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
6de649ce
Commit
6de649ce
authored
Jan 03, 2025
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.管道刷历史数据
parent
6365c013
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
4 deletions
+7
-4
JgInstallationNoticeMapper.xml
.../src/main/resources/mapper/JgInstallationNoticeMapper.xml
+1
-0
DataHandlerServiceImpl.java
...ot/module/jg/biz/service/impl/DataHandlerServiceImpl.java
+6
-4
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgInstallationNoticeMapper.xml
View file @
6de649ce
...
...
@@ -335,5 +335,6 @@
where
re.equip_transfer_id = #{useRegisterId} limit 1
)
limit 1
</select>
</mapper>
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/DataHandlerServiceImpl.java
View file @
6de649ce
...
...
@@ -544,7 +544,7 @@ public class DataHandlerServiceImpl {
esEquipmentCategory
.
save
(
equInfoEs
);
});
}
// 2.安装告知非已作废,但是缺少装置
的数据处理:创建装置(计算管道长度)
、写入安装告知表project_contraption_id、写入设备es的装置id,设备使用信息表的projectContraptionId
// 2.安装告知非已作废,但是缺少装置
id的数据处理:创建装置
、写入安装告知表project_contraption_id、写入设备es的装置id,设备使用信息表的projectContraptionId
List
<
JgInstallationNotice
>
noticeList
=
getErrorInstallNoticeData
();
log
.
info
(
"处理前:2.安装告知非已作废,但是缺少装置id安装告知单据数量:{}"
,
noticeList
.
size
());
List
<
IdxBizJgProjectContraption
>
projectContraptionList
=
new
ArrayList
<>();
...
...
@@ -581,6 +581,7 @@ public class DataHandlerServiceImpl {
.
one
();
Long
sequenceNbr
=
sequence
.
nextId
();
installationNotice
.
setProjectContraptionId
(
sequenceNbr
+
""
);
// key为装置id,value为此装置下的管道数组
projectContraptionIdRecordsMap
.
put
(
sequenceNbr
,
records
);
IdxBizJgProjectContraption
idxBizJgProjectContraption
=
IdxBizJgProjectContraption
.
builder
()
.
projectContraption
(
installationNotice
.
getProjectContraption
())
...
...
@@ -592,7 +593,7 @@ public class DataHandlerServiceImpl {
.
equCategory
(
installationNotice
.
getEquCategoryCode
())
.
equCategoryName
(
ObjectUtils
.
isEmpty
(
installationNotice
.
getEquCategoryCode
())
?
null
:
equipmentCategoryMapper
.
selectOne
(
new
LambdaQueryWrapper
<
EquipmentCategory
>().
eq
(
EquipmentCategory:
:
getCode
,
installationNotice
.
getEquCategoryCode
())).
getName
())
.
equDefine
(
ObjectUtils
.
isEmpty
(
registerInfo
)
?
null
:
registerInfo
.
getEquDefine
())
.
equDefineName
(
ObjectUtils
.
isEmpty
(
ObjectUtils
.
isEmpty
(
registerInfo
)
?
null
:
registerInfo
.
getEquDefine
())
?
null
:
equipmentCategoryMapper
.
selectOne
(
new
LambdaQueryWrapper
<
EquipmentCategory
>().
eq
(
EquipmentCategory:
:
getCode
,
(
ObjectUtils
.
isEmpty
(
registerInfo
)
?
null
:
registerInfo
.
getEquDefine
()
))).
getName
())
.
equDefineName
(
ObjectUtils
.
isEmpty
(
ObjectUtils
.
isEmpty
(
registerInfo
)
?
null
:
registerInfo
.
getEquDefine
())
?
null
:
equipmentCategoryMapper
.
selectOne
(
new
LambdaQueryWrapper
<
EquipmentCategory
>().
eq
(
EquipmentCategory:
:
getCode
,
registerInfo
.
getEquDefine
(
))).
getName
())
.
content
(
null
)
.
pipelineLength
(
pipeLengthSumBig
.
doubleValue
())
.
productPhoto
(
ObjectUtils
.
isEmpty
(
registerInfo
)
?
null
:
registerInfo
.
getProductPhoto
())
...
...
@@ -654,13 +655,14 @@ public class DataHandlerServiceImpl {
log
.
info
(
"处理前:1.使用登记装置id历史数据填充,存在缺少装置id的单据数量:{}"
,
useRegistrations
.
size
());
// 循环按照使用登记的eq表关联安装告知eq表,在安装告知主表查询装置id
for
(
JgUseRegistration
useRegistration
:
useRegistrations
){
// 登记的关联的告知单据
// 登记的关联的告知单据
【逻辑按照eq进行关联】
JgInstallationNotice
installationNotice
=
installationNoticeService
.
getBaseMapper
().
selectNoticeDataByUseRegisterId
(
useRegistration
.
getSequenceNbr
()
+
""
);
if
(
installationNotice
!=
null
&&
StringUtils
.
isNotEmpty
(
installationNotice
.
getProjectContraptionId
())){
// 1.填充装置id
useRegistration
.
setProjectContraptionId
(
installationNotice
.
getProjectContraptionId
());
// 2.已完成状状态清除装置表的安装单位信息字段,填充使用信息数据,
if
(
FlowStatusEnum
.
TO_BE_FINISHED
.
getName
().
equals
(
useRegistration
.
getStatus
())){
// 特殊处理 将任意一个的 record 放入到remark字段
IdxBizJgUseInfo
useInfo
=
getIdxBizJgUseInfo
(
installationNotice
.
getRemark
());
LambdaUpdateWrapper
<
IdxBizJgProjectContraption
>
updateWrapper
=
new
LambdaUpdateWrapper
<>();
updateWrapper
.
eq
(
BaseEntity:
:
getSequenceNbr
,
installationNotice
.
getProjectContraptionId
());
...
...
@@ -697,6 +699,6 @@ public class DataHandlerServiceImpl {
.
ne
(
JgUseRegistration:
:
getStatus
,
FlowStatusEnum
.
TO_BE_DISCARD
.
getName
())
.
ne
(
JgUseRegistration:
:
getProjectContraption
,
""
)
.
isNull
(
JgUseRegistration:
:
getProjectContraptionId
)
.
select
(
BaseEntity:
:
getSequenceNbr
,
JgUseRegistration:
:
getProjectContraption
,
JgUseRegistration:
:
getUseRegistrationCode
));
.
select
(
BaseEntity:
:
getSequenceNbr
,
JgUseRegistration:
:
getProjectContraption
,
JgUseRegistration:
:
getUseRegistrationCode
,
JgUseRegistration:
:
getStatus
));
}
}
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