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
257813b0
Commit
257813b0
authored
Jul 18, 2024
by
tianyiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
安装告知作废后将设备改为未纳管状态
parent
7fd2fa47
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
0 deletions
+24
-0
JgInstallationNoticeServiceImpl.java
.../jg/biz/service/impl/JgInstallationNoticeServiceImpl.java
+24
-0
No files found.
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/JgInstallationNoticeServiceImpl.java
View file @
257813b0
...
...
@@ -115,6 +115,8 @@ public class JgInstallationNoticeServiceImpl extends BaseService<JgInstallationN
@Autowired
JgUseRegistrationMapper
jgUseRegistrationMapper
;
@Autowired
IdxBizJgUseInfoServiceImpl
idxBizJgUseInfoService
;
@Autowired
IdxBizJgRegisterInfoServiceImpl
idxBizJgRegisterInfoService
;
@Autowired
IdxBizJgRegisterInfoMapper
tzsJgRegistrationInfoMapper
;
...
...
@@ -1394,6 +1396,28 @@ public class JgInstallationNoticeServiceImpl extends BaseService<JgInstallationN
this
.
updateById
(
installationNotice
);
// 2.更新关联的业务
this
.
processElseDataByStatus
(
Objects
.
requireNonNull
(
FlowStatusEnum
.
getEumByCode
(
Integer
.
parseInt
(
oldNoticeStatus
))),
installationNotice
);
// 3.更新ES、IdxBizJgUseInfo中关联设备为未纳管
Map
<
String
,
Map
<
String
,
Object
>>
objMap
=
new
HashMap
<>();
LambdaQueryWrapper
<
JgInstallationNoticeEq
>
lambdaQueryWrapper
=
new
LambdaQueryWrapper
();
lambdaQueryWrapper
.
eq
(
JgInstallationNoticeEq:
:
getEquipTransferId
,
installationNotice
.
getSequenceNbr
());
List
<
JgInstallationNoticeEq
>
jgInstallationNoticeEqs
=
jgInstallationNoticeEqMapper
.
selectList
(
lambdaQueryWrapper
);
if
(!
ObjectUtils
.
isEmpty
(
jgInstallationNoticeEqs
)
&&
jgInstallationNoticeEqs
.
size
()
>
0
)
{
for
(
JgInstallationNoticeEq
jgInstallationNoticeEq
:
jgInstallationNoticeEqs
)
{
// 组装修改es条件及数据
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"IS_INTO_MANAGEMENT"
,
Boolean
.
FALSE
);
objMap
.
put
(
jgInstallationNoticeEq
.
getEquId
(),
map
);
}
}
// 组装更新IdxBizJgUseInfo条件
LambdaQueryWrapper
<
IdxBizJgUseInfo
>
jgUseInfoLambdaQueryWrapper
=
new
LambdaQueryWrapper
<>();
jgUseInfoLambdaQueryWrapper
.
in
(
IdxBizJgUseInfo:
:
getRecord
,
jgInstallationNoticeEqs
.
stream
().
map
(
JgInstallationNoticeEq:
:
getEquId
).
collect
(
Collectors
.
toList
()));
List
<
IdxBizJgUseInfo
>
list
=
idxBizJgUseInfoMapper
.
selectList
(
jgUseInfoLambdaQueryWrapper
);
for
(
IdxBizJgUseInfo
useInfo
:
list
)
{
useInfo
.
setIsIntoManagement
(
Boolean
.
FALSE
);
}
idxBizJgUseInfoService
.
saveOrUpdateBatch
(
list
);
tzsServiceFeignClient
.
commonUpdateEsDataByIds
(
objMap
);
return
installationNotice
;
}
...
...
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