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
5663866c
Commit
5663866c
authored
Jan 31, 2024
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.报检结果接收接口开发
parent
53396c1f
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
459 additions
and
0 deletions
+459
-0
BizCustomDateSerializer.java
.../boot/module/jyjc/api/common/BizCustomDateSerializer.java
+71
-0
AttachmentData.java
...ejoin/amos/boot/module/jyjc/api/model/AttachmentData.java
+21
-0
AttachmentModel.java
...join/amos/boot/module/jyjc/api/model/AttachmentModel.java
+31
-0
JyjcInspectionResultDataModel.java
.../module/jyjc/api/model/JyjcInspectionResultDataModel.java
+85
-0
JyjcInspectionResultController.java
...e/jyjc/biz/controller/JyjcInspectionResultController.java
+12
-0
InspectionDetectionSaveToDbEvent.java
...dule/jyjc/biz/event/InspectionDetectionSaveToDbEvent.java
+27
-0
UseInfoSaveToDbEvent.java
...amos/boot/module/jyjc/biz/event/UseInfoSaveToDbEvent.java
+27
-0
InspectionDetectionSaveToDbEventListener.java
...nt/listener/InspectionDetectionSaveToDbEventListener.java
+106
-0
UseInfoSaveToDbEventListener.java
...jyjc/biz/event/listener/UseInfoSaveToDbEventListener.java
+58
-0
EventPublisher.java
.../boot/module/jyjc/biz/event/publisher/EventPublisher.java
+21
-0
JyjcInspectionResultServiceImpl.java
...yjc/biz/service/impl/JyjcInspectionResultServiceImpl.java
+0
-0
No files found.
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-api/src/main/java/com/yeejoin/amos/boot/module/jyjc/api/common/BizCustomDateSerializer.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
api
.
common
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.core.JsonGenerator
;
import
com.fasterxml.jackson.core.JsonProcessingException
;
import
com.fasterxml.jackson.databind.JsonSerializer
;
import
com.fasterxml.jackson.databind.SerializerProvider
;
import
org.apache.commons.lang3.StringUtils
;
import
org.typroject.tyboot.core.foundation.utils.DateTimeUtil
;
import
java.io.IOException
;
import
java.lang.reflect.Field
;
import
java.text.SimpleDateFormat
;
import
java.util.*
;
/**
* @JsonComponent 会覆盖JsonFormat, 这里解析字段提升JsonFormat优先级
* <p>
* ProjectName: amos-boot-biz
* PackageName: com.yeejoin.amos.boot.module.jg.biz.config
*
* @author yangyang
* @version v1.0
* @date 2023/12/18 17:35
*/
public
class
BizCustomDateSerializer
extends
JsonSerializer
<
Date
>
{
private
List
<
String
>
customFields
=
Arrays
.
asList
(
"acceptDate"
,
"expiryDate"
,
"applicationDate"
,
"noticeDate"
,
"installStartDate"
,
"handleDate"
,
"auditPassDate"
,
"applyDate"
);
public
BizCustomDateSerializer
()
{
}
@Override
public
void
serialize
(
Date
value
,
JsonGenerator
jgen
,
SerializerProvider
provider
)
throws
IOException
,
JsonProcessingException
{
try
{
Class
<?>
clazz
=
jgen
.
getCurrentValue
().
getClass
();
if
(
Objects
.
equals
(
clazz
,
HashMap
.
class
))
{
// 分页参数
if
(
customFields
.
contains
(
jgen
.
getOutputContext
().
getCurrentName
()))
{
SimpleDateFormat
formatter
=
new
SimpleDateFormat
(
DateTimeUtil
.
ISO_DATE
);
jgen
.
writeString
(
formatter
.
format
(
value
));
return
;
}
}
else
{
Field
field
=
clazz
.
getDeclaredField
(
jgen
.
getOutputContext
().
getCurrentName
());
if
(
Objects
.
equals
(
field
.
getType
(),
Date
.
class
))
{
if
(
field
.
isAnnotationPresent
(
JsonFormat
.
class
))
{
String
pattern
=
field
.
getAnnotation
(
JsonFormat
.
class
).
pattern
();
if
(
StringUtils
.
isNotBlank
(
pattern
))
{
SimpleDateFormat
formatter
=
new
SimpleDateFormat
(
pattern
);
jgen
.
writeString
(
formatter
.
format
(
value
));
return
;
}
}
}
}
jgen
.
writeString
(
defaultFormattedDate
(
value
));
}
catch
(
Exception
e
)
{
jgen
.
writeString
(
defaultFormattedDate
(
value
));
}
}
private
String
defaultFormattedDate
(
Date
value
)
{
SimpleDateFormat
formatter
=
new
SimpleDateFormat
(
DateTimeUtil
.
ISO_DATE_HOUR24_MIN_SEC
);
String
formattedDate
=
formatter
.
format
(
value
);
return
formattedDate
;
}
}
\ No newline at end of file
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-api/src/main/java/com/yeejoin/amos/boot/module/jyjc/api/model/AttachmentData.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
api
.
model
;
import
lombok.Data
;
import
java.util.List
;
/**
* @author Administrator
*/
@Data
public
class
AttachmentData
{
/**
* 附件类型
*/
public
String
attachmentType
;
/**
* 附件列表
*/
public
List
<
AttachmentModel
>
attachmentContent
;
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-api/src/main/java/com/yeejoin/amos/boot/module/jyjc/api/model/AttachmentModel.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
api
.
model
;
import
lombok.Data
;
/**
* @author Administrator
* 附件结构
*/
@Data
public
class
AttachmentModel
{
/**
* 附件名称
*/
String
name
;
/**
* 附件路径
*/
String
url
;
/**
* 前端标识
*/
String
uid
;
/**
* 前端附件状态
*/
String
status
;
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-api/src/main/java/com/yeejoin/amos/boot/module/jyjc/api/model/JyjcInspectionResultDataModel.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
api
.
model
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.fasterxml.jackson.databind.annotation.JsonSerialize
;
import
com.yeejoin.amos.boot.module.jyjc.api.common.BizCustomDateSerializer
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.util.Date
;
import
java.util.List
;
/**
* 业务开通申请表
*
* @author system_generator
* @date 2023-12-14
*/
@Data
@ApiModel
(
value
=
"JyjcInspectionResultDataModel"
,
description
=
"检验检测结果数据接收"
)
public
class
JyjcInspectionResultDataModel
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"报检单号"
)
private
String
applicationNo
;
@ApiModelProperty
(
value
=
"监管码"
)
private
String
supervisoryCode
;
@ApiModelProperty
(
value
=
"检验结果状态(已出2、未出1)"
)
private
String
resultStatus
;
@ApiModelProperty
(
value
=
"核准证号/许可证号"
)
private
String
licenseNumber
;
@ApiModelProperty
(
value
=
"检验报告编号"
)
private
String
resultNo
;
@ApiModelProperty
(
value
=
"内部人员代码"
)
private
String
innerPersonCode
;
@ApiModelProperty
(
value
=
"检验结论"
)
private
String
inspectionConclusion
;
@ApiModelProperty
(
value
=
"检验日期"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonSerialize
(
using
=
BizCustomDateSerializer
.
class
)
private
Date
inspectionDate
;
@ApiModelProperty
(
value
=
"下次检验日期"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonSerialize
(
using
=
BizCustomDateSerializer
.
class
)
private
Date
nextInspectionDate
;
@ApiModelProperty
(
value
=
"检验开始日期"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonSerialize
(
using
=
BizCustomDateSerializer
.
class
)
private
Date
inspectionStartDate
;
@ApiModelProperty
(
value
=
"检验结束日期"
)
@JsonFormat
(
pattern
=
"yyyy-MM-dd"
)
@JsonSerialize
(
using
=
BizCustomDateSerializer
.
class
)
private
Date
inspectionEndDate
;
@ApiModelProperty
(
value
=
"检验结果汇总"
)
private
String
inspectionResultSummary
;
@ApiModelProperty
(
value
=
"不符合项"
)
private
JSONArray
nonConformance
;
@ApiModelProperty
(
value
=
"附件"
)
private
List
<
AttachmentData
>
attachments
;
@ApiModelProperty
(
value
=
"检验结果技术参数"
)
private
JSONObject
techParams
;
/**
* 校验检验系统唯一流水号,排查问题,跟踪问题使用
*/
private
String
traceId
;
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/controller/JyjcInspectionResultController.java
View file @
5663866c
...
@@ -2,6 +2,7 @@ package com.yeejoin.amos.boot.module.jyjc.biz.controller;
...
@@ -2,6 +2,7 @@ package com.yeejoin.amos.boot.module.jyjc.biz.controller;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.module.jyjc.api.model.JyjcInspectionResultDataModel
;
import
com.yeejoin.amos.boot.module.jyjc.api.model.JyjcInspectionResultModel
;
import
com.yeejoin.amos.boot.module.jyjc.api.model.JyjcInspectionResultModel
;
import
com.yeejoin.amos.boot.module.jyjc.biz.service.impl.JyjcInspectionResultServiceImpl
;
import
com.yeejoin.amos.boot.module.jyjc.biz.service.impl.JyjcInspectionResultServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
...
@@ -175,4 +176,15 @@ public class JyjcInspectionResultController extends BaseController {
...
@@ -175,4 +176,15 @@ public class JyjcInspectionResultController extends BaseController {
return
ResponseHelper
.
buildResponse
(
jyjcInspectionResultServiceImpl
.
equipList
(
type
,
notNode
));
return
ResponseHelper
.
buildResponse
(
jyjcInspectionResultServiceImpl
.
equipList
(
type
,
notNode
));
}
}
/**
* 报检结果接收
* @param resultDataModels 结果信息
* @return List<JyjcInspectionResultDataModel>
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"报检结果接收"
,
notes
=
"对外对接使用,支持单条及批量"
)
@PostMapping
(
value
=
"/receive/data"
)
public
ResponseModel
<
List
<
JyjcInspectionResultDataModel
>>
receivePushResultData
(
@RequestBody
List
<
JyjcInspectionResultDataModel
>
resultDataModels
){
return
ResponseHelper
.
buildResponse
(
jyjcInspectionResultServiceImpl
.
receivePushResultData
(
resultDataModels
));
}
}
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/event/InspectionDetectionSaveToDbEvent.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
biz
.
event
;
import
com.yeejoin.amos.boot.module.jyjc.api.entity.JyjcInspectionResult
;
import
lombok.Getter
;
import
org.springframework.context.ApplicationEvent
;
import
java.util.List
;
/**
* @author Administrator
*/
@Getter
public
class
InspectionDetectionSaveToDbEvent
extends
ApplicationEvent
{
private
List
<
JyjcInspectionResult
>
jyjcInspectionResultList
;
/**
* Create a new {@code ApplicationEvent}.
*
* @param source the object on which the event initially occurred or with
* which the event is associated (never {@code null})
*/
public
InspectionDetectionSaveToDbEvent
(
Object
source
,
List
<
JyjcInspectionResult
>
jyjcInspectionResultList
)
{
super
(
source
);
this
.
jyjcInspectionResultList
=
jyjcInspectionResultList
;
}
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/event/UseInfoSaveToDbEvent.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
biz
.
event
;
import
com.yeejoin.amos.boot.module.jyjc.api.entity.JyjcInspectionResult
;
import
lombok.Getter
;
import
org.springframework.context.ApplicationEvent
;
import
java.util.List
;
/**
* @author Administrator
*/
@Getter
public
class
UseInfoSaveToDbEvent
extends
ApplicationEvent
{
private
List
<
JyjcInspectionResult
>
jyjcInspectionResultList
;
/**
* Create a new {@code ApplicationEvent}.
*
* @param source the object on which the event initially occurred or with
* which the event is associated (never {@code null})
*/
public
UseInfoSaveToDbEvent
(
Object
source
,
List
<
JyjcInspectionResult
>
jyjcInspectionResultList
)
{
super
(
source
);
this
.
jyjcInspectionResultList
=
jyjcInspectionResultList
;
}
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/event/listener/InspectionDetectionSaveToDbEventListener.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
biz
.
event
.
listener
;
import
com.alibaba.fastjson.JSONObject
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.toolkit.Sequence
;
import
com.yeejoin.amos.boot.module.jyjc.api.entity.JyjcInspectionResult
;
import
com.yeejoin.amos.boot.module.jyjc.biz.event.InspectionDetectionSaveToDbEvent
;
import
com.yeejoin.amos.boot.module.jyjc.biz.service.impl.CommonserviceImpl
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.InspectionDetectionInfo
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.TzsUserInfo
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.InspectionDetectionInfoMapper
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.context.ApplicationListener
;
import
org.springframework.stereotype.Component
;
import
org.springframework.util.CollectionUtils
;
import
javax.annotation.PostConstruct
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.concurrent.BlockingQueue
;
import
java.util.concurrent.ExecutorService
;
import
java.util.concurrent.Executors
;
import
java.util.concurrent.LinkedBlockingQueue
;
import
java.util.stream.Collectors
;
/**
* @author Administrator
*/
@Component
@Slf4j
public
class
InspectionDetectionSaveToDbEventListener
implements
ApplicationListener
<
InspectionDetectionSaveToDbEvent
>
{
@Value
(
"${inspect.info.save.thread.number:3}"
)
private
int
threadNumber
;
@Autowired
CommonserviceImpl
commonService
;
@Autowired
private
Sequence
sequence
;
@Autowired
InspectionDetectionInfoMapper
inspectionDetectionInfoMapper
;
private
BlockingQueue
<
JyjcInspectionResult
>
blockingQueue
=
new
LinkedBlockingQueue
<>();
@Override
public
void
onApplicationEvent
(
InspectionDetectionSaveToDbEvent
event
)
{
log
.
info
(
"收到检验检测信息插入或者更新消息:{}"
,
JSONObject
.
toJSONString
(
event
.
getJyjcInspectionResultList
()));
blockingQueue
.
addAll
(
event
.
getJyjcInspectionResultList
());
}
@PostConstruct
public
void
init
()
{
ExecutorService
executorService
=
Executors
.
newFixedThreadPool
(
threadNumber
);
for
(
int
i
=
0
;
i
<
threadNumber
;
i
++)
{
executorService
.
execute
(()
->
{
while
(
true
)
{
try
{
JyjcInspectionResult
jyjcInspectionResult
=
blockingQueue
.
take
();
InspectionDetectionInfo
info
=
new
InspectionDetectionInfo
();
QueryWrapper
<
InspectionDetectionInfo
>
wrapper
=
new
QueryWrapper
<>();
wrapper
.
lambda
().
eq
(
InspectionDetectionInfo:
:
getInspectReportNo
,
jyjcInspectionResult
.
getResultNo
());
List
<
InspectionDetectionInfo
>
list
=
inspectionDetectionInfoMapper
.
selectList
(
wrapper
);
if
(
CollectionUtils
.
isEmpty
(
list
))
{
extracted
(
jyjcInspectionResult
,
info
);
info
.
setSequenceNbr
(
sequence
.
nextId
()
+
""
);
inspectionDetectionInfoMapper
.
insert
(
info
);
}
else
{
info
=
list
.
get
(
0
);
extracted
(
jyjcInspectionResult
,
info
);
inspectionDetectionInfoMapper
.
updateById
(
info
);
}
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
}
}
});
}
}
private
void
extracted
(
JyjcInspectionResult
jyjcInspectionResult
,
InspectionDetectionInfo
info
)
{
info
.
setInspectOrgName
(
jyjcInspectionResult
.
getInspectionTypeName
());
info
.
setInspectType
(
jyjcInspectionResult
.
getInspectionType
());
info
.
setRecord
(
jyjcInspectionResult
.
getEquipUnicode
());
info
.
setInspectDate
(
jyjcInspectionResult
.
getInspectionDate
());
info
.
setInspectStaff
(
getInspectUserName
(
jyjcInspectionResult
));
info
.
setInspectStaffCode
(
jyjcInspectionResult
.
getInspector
());
info
.
setInspectConclusion
(
jyjcInspectionResult
.
getInspectionConclusion
());
info
.
setProblemRemark
(
jyjcInspectionResult
.
getNonConformance
());
info
.
setNextInspectDate
(
jyjcInspectionResult
.
getNextInspectionDate
());
info
.
setSequenceCode
(
jyjcInspectionResult
.
getEquipUnicode
());
info
.
setInspectOrgCode
(
jyjcInspectionResult
.
getInspectionUnitCode
());
info
.
setInspectReportNo
(
jyjcInspectionResult
.
getResultNo
());
info
.
setRecDate
(
new
Date
());
}
private
String
getInspectUserName
(
JyjcInspectionResult
model
)
{
List
<
TzsUserInfo
>
userInfos
=
commonService
.
getUserInfosByUnitCode
(
model
.
getInspectionUnitCode
());
return
userInfos
.
stream
().
filter
(
u
->
model
.
getInspector
().
contains
(
u
.
getSequenceNbr
()
+
""
)).
map
(
TzsUserInfo:
:
getName
).
collect
(
Collectors
.
joining
(
","
));
}
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/event/listener/UseInfoSaveToDbEventListener.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
biz
.
event
.
listener
;
import
com.alibaba.fastjson.JSONObject
;
import
com.yeejoin.amos.boot.module.jyjc.api.entity.JyjcInspectionResult
;
import
com.yeejoin.amos.boot.module.jyjc.biz.event.UseInfoSaveToDbEvent
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.UseInfoMapper
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.context.ApplicationListener
;
import
org.springframework.stereotype.Component
;
import
javax.annotation.PostConstruct
;
import
java.util.concurrent.BlockingQueue
;
import
java.util.concurrent.ExecutorService
;
import
java.util.concurrent.Executors
;
import
java.util.concurrent.LinkedBlockingQueue
;
/**
* @author Administrator
*/
@Component
@Slf4j
public
class
UseInfoSaveToDbEventListener
implements
ApplicationListener
<
UseInfoSaveToDbEvent
>
{
@Value
(
"${user.info.save.thread.number:3}"
)
private
int
threadNumber
;
@Autowired
UseInfoMapper
useInfoMapper
;
private
BlockingQueue
<
JyjcInspectionResult
>
blockingQueue
=
new
LinkedBlockingQueue
<>();
@Override
public
void
onApplicationEvent
(
UseInfoSaveToDbEvent
event
)
{
log
.
info
(
"收到更新使用信息的检验检测字段消息:{}"
,
JSONObject
.
toJSONString
(
event
.
getJyjcInspectionResultList
()));
blockingQueue
.
addAll
(
event
.
getJyjcInspectionResultList
());
}
@PostConstruct
public
void
init
()
{
ExecutorService
executorService
=
Executors
.
newFixedThreadPool
(
threadNumber
);
for
(
int
i
=
0
;
i
<
threadNumber
;
i
++)
{
executorService
.
execute
(()
->
{
while
(
true
)
{
try
{
JyjcInspectionResult
jyjcInspectionResult
=
blockingQueue
.
take
();
//更新使用信息表
useInfoMapper
.
updateByRecord
(
jyjcInspectionResult
.
getEquipUnicode
(),
jyjcInspectionResult
.
getNextInspectionDate
(),
jyjcInspectionResult
.
getInspectionType
(),
jyjcInspectionResult
.
getApplicationNo
());
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
}
}
});
}
}
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/event/publisher/EventPublisher.java
0 → 100644
View file @
5663866c
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
biz
.
event
.
publisher
;
import
org.springframework.context.ApplicationEvent
;
import
org.springframework.context.ApplicationEventPublisher
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.stereotype.Component
;
@Component
public
class
EventPublisher
{
private
ApplicationEventPublisher
publisher
;
public
EventPublisher
(
ApplicationEventPublisher
publisher
)
{
this
.
publisher
=
publisher
;
}
@Async
public
void
publish
(
ApplicationEvent
event
)
{
publisher
.
publishEvent
(
event
);
}
}
\ No newline at end of file
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 @
5663866c
This diff is collapsed.
Click to expand it.
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