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
c682eb68
Commit
c682eb68
authored
Aug 18, 2025
by
hcing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(jyjc): 报检结果更新时刷新设备对应的安全追溯问题
parent
155b74a9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
3 deletions
+29
-3
JyjcInspectionResultServiceImpl.java
...yjc/biz/service/impl/JyjcInspectionResultServiceImpl.java
+29
-3
No files found.
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/service/impl/JyjcInspectionResultServiceImpl.java
View file @
c682eb68
...
@@ -179,10 +179,10 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
...
@@ -179,10 +179,10 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
model
=
new
JyjcInspectionResultModel
();
model
=
new
JyjcInspectionResultModel
();
}
}
if
(
type
)
{
if
(
type
)
{
//检验检测单位分页查询
//
检验检测单位分页查询
model
.
setInspectionUnitCode
(
reginParams
.
getCompany
().
getCompanyCode
());
model
.
setInspectionUnitCode
(
reginParams
.
getCompany
().
getCompanyCode
());
}
else
{
}
else
{
//报检单位分页查询
//
报检单位分页查询
model
.
setApplicationUnitCode
(
reginParams
.
getCompany
().
getCompanyCode
());
model
.
setApplicationUnitCode
(
reginParams
.
getCompany
().
getCompanyCode
());
}
}
Page
<
JyjcInspectionResultModel
>
resultPage
=
resultMapper
.
selectJyjcInspectionResultpPage
(
page
,
model
);
Page
<
JyjcInspectionResultModel
>
resultPage
=
resultMapper
.
selectJyjcInspectionResultpPage
(
page
,
model
);
...
@@ -806,12 +806,13 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
...
@@ -806,12 +806,13 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
useInfoMapper
.
updateByRecord
(
inspectionDetectionInfo
.
getRecord
(),
jyjcInspectionResult
.
getNextInspectionDate
(),
jyjcInspectionResult
.
getInspectionType
(),
jyjcInspectionResult
.
getApplicationNo
());
useInfoMapper
.
updateByRecord
(
inspectionDetectionInfo
.
getRecord
(),
jyjcInspectionResult
.
getNextInspectionDate
(),
jyjcInspectionResult
.
getInspectionType
(),
jyjcInspectionResult
.
getApplicationNo
());
// 4.更新es下次检验日期
// 4.更新es下次检验日期
commonService
.
updateEquipNextInspectDate
(
jyjcInspectionResult
,
inspectionDetectionInfo
.
getRecord
());
commonService
.
updateEquipNextInspectDate
(
jyjcInspectionResult
,
inspectionDetectionInfo
.
getRecord
());
sendDataRefreshMsg
(
records
);
bizEmqPublisher
.
sendInspectionMsgAfterSave
(
inspectionDetectionInfo
,
"insert"
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
warn
(
e
.
getMessage
());
log
.
warn
(
e
.
getMessage
());
throw
new
BadRequest
(
"数据异常,请联系管理员!"
);
throw
new
BadRequest
(
"数据异常,请联系管理员!"
);
}
}
}
}
sendDataRefreshMsg
(
records
);
return
Boolean
.
TRUE
;
return
Boolean
.
TRUE
;
}
}
...
@@ -940,6 +941,7 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
...
@@ -940,6 +941,7 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
commonService
.
updateEquipNextInspectDate
(
jyjcInspectionResult
,
inspectionDetectionInfo
.
getRecord
());
commonService
.
updateEquipNextInspectDate
(
jyjcInspectionResult
,
inspectionDetectionInfo
.
getRecord
());
// 发送数据变更消息
// 发送数据变更消息
sendDataRefreshMsg
(
Sets
.
newHashSet
(
inspectionDetectionInfo
.
getRecord
()));
sendDataRefreshMsg
(
Sets
.
newHashSet
(
inspectionDetectionInfo
.
getRecord
()));
bizEmqPublisher
.
sendInspectionMsgAfterSave
(
inspectionDetectionInfo
,
"update"
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
log
.
error
(
e
.
getMessage
(),
e
);
throw
new
BadRequest
(
"数据异常,请联系管理员!"
);
throw
new
BadRequest
(
"数据异常,请联系管理员!"
);
...
@@ -976,9 +978,33 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
...
@@ -976,9 +978,33 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
jyjcInspectionHistoryService
.
getBaseMapper
().
delete
(
new
LambdaQueryWrapper
<
JyjcInspectionHistory
>().
eq
(
JyjcInspectionHistory:
:
getSSeq
,
resultSeq
));
jyjcInspectionHistoryService
.
getBaseMapper
().
delete
(
new
LambdaQueryWrapper
<
JyjcInspectionHistory
>().
eq
(
JyjcInspectionHistory:
:
getSSeq
,
resultSeq
));
// 发送数据变更消息
// 发送数据变更消息
sendDataRefreshMsg
(
records
);
sendDataRefreshMsg
(
records
);
records
.
stream
()
.
filter
(
Objects:
:
nonNull
)
.
map
(
this
::
getTheLatestInspectionInformation
)
.
filter
(
Objects:
:
nonNull
)
.
forEach
(
info
->
bizEmqPublisher
.
sendInspectionMsgAfterSave
(
info
,
"update"
));
return
Boolean
.
TRUE
;
return
Boolean
.
TRUE
;
}
}
/**
* 获取最新的一条检验检测信息
*
* @param record 设备 record
* @return 最新的一条检验检测信息
*/
private
IdxBizJgInspectionDetectionInfo
getTheLatestInspectionInformation
(
String
record
)
{
List
<
IdxBizJgInspectionDetectionInfo
>
inspectionDetectionInfoList
=
idxBizJgInspectionDetectionInfoMapper
.
selectList
(
new
LambdaQueryWrapper
<
IdxBizJgInspectionDetectionInfo
>()
.
eq
(
IdxBizJgInspectionDetectionInfo:
:
getRecord
,
record
)
.
orderByDesc
(
IdxBizJgInspectionDetectionInfo:
:
getInspectDate
)
.
last
(
"LIMIT 1"
)
);
return
inspectionDetectionInfoList
.
stream
()
.
findFirst
()
.
orElse
(
null
);
}
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
List
<
PipelineInspectionResultDto
>
receivePipelineResultData
(
List
<
PipelineInspectionResultDto
>
resultData
)
{
public
List
<
PipelineInspectionResultDto
>
receivePipelineResultData
(
List
<
PipelineInspectionResultDto
>
resultData
)
{
log
.
info
(
"收到检验检测厂商推送的压力管道结果数据:{}"
,
JSONArray
.
toJSONString
(
resultData
));
log
.
info
(
"收到检验检测厂商推送的压力管道结果数据:{}"
,
JSONArray
.
toJSONString
(
resultData
));
...
...
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