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
a664cfa6
Commit
a664cfa6
authored
Nov 08, 2024
by
韩桐桐
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(jyjc):登记机关名称处理
parent
c0b2e138
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
13 deletions
+14
-13
JgUseRegistrationManage.java
...os/boot/module/jg/api/entity/JgUseRegistrationManage.java
+0
-8
InspectionApplicationPushEventListener.java
...vent/listener/InspectionApplicationPushEventListener.java
+14
-5
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/entity/JgUseRegistrationManage.java
View file @
a664cfa6
...
@@ -208,12 +208,4 @@ public class JgUseRegistrationManage extends BaseEntity {
...
@@ -208,12 +208,4 @@ public class JgUseRegistrationManage extends BaseEntity {
*/
*/
@TableField
(
"change_reason"
)
@TableField
(
"change_reason"
)
private
String
changeReason
;
private
String
changeReason
;
/**
*
* 登记机关名称
*/
@TableField
(
"reg_unit_name"
)
private
String
regUnitName
;
}
}
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/InspectionApplicationPushEventListener.java
View file @
a664cfa6
...
@@ -21,6 +21,7 @@ import com.yeejoin.amos.boot.module.jyjc.biz.event.InspectionApplicationPushEven
...
@@ -21,6 +21,7 @@ import com.yeejoin.amos.boot.module.jyjc.biz.event.InspectionApplicationPushEven
import
com.yeejoin.amos.boot.module.jyjc.biz.kafka.KafkaProducer
;
import
com.yeejoin.amos.boot.module.jyjc.biz.kafka.KafkaProducer
;
import
com.yeejoin.amos.boot.module.jyjc.biz.service.impl.JyjcInspectionApplicationEquipServiceImpl
;
import
com.yeejoin.amos.boot.module.jyjc.biz.service.impl.JyjcInspectionApplicationEquipServiceImpl
;
import
com.yeejoin.amos.boot.module.jyjc.biz.service.impl.JyjcInspectionApplicationPushLogServiceImpl
;
import
com.yeejoin.amos.boot.module.jyjc.biz.service.impl.JyjcInspectionApplicationPushLogServiceImpl
;
import
com.yeejoin.amos.boot.module.jyjc.biz.util.JsonUtils
;
import
com.yeejoin.amos.boot.module.jyjc.biz.util.JyjcConstant
;
import
com.yeejoin.amos.boot.module.jyjc.biz.util.JyjcConstant
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.*
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.*
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.*
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.*
;
...
@@ -28,6 +29,7 @@ import lombok.extern.slf4j.Slf4j;
...
@@ -28,6 +29,7 @@ import lombok.extern.slf4j.Slf4j;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.context.ApplicationListener
;
import
org.springframework.context.ApplicationListener
;
import
org.springframework.core.io.Resource
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Component
;
import
javax.annotation.PostConstruct
;
import
javax.annotation.PostConstruct
;
...
@@ -45,6 +47,11 @@ import java.util.stream.Collectors;
...
@@ -45,6 +47,11 @@ import java.util.stream.Collectors;
@Slf4j
@Slf4j
public
class
InspectionApplicationPushEventListener
implements
ApplicationListener
<
InspectionApplicationPushEvent
>
{
public
class
InspectionApplicationPushEventListener
implements
ApplicationListener
<
InspectionApplicationPushEvent
>
{
@Value
(
"classpath:/json/companyCodeRegName.json"
)
private
Resource
regNameJson
;
private
Map
<
String
,
String
>
companyCodeRegNameMap
;
private
BlockingQueue
<
JyjcInspectionApplicationModel
>
queue
=
new
LinkedBlockingQueue
<>();
private
BlockingQueue
<
JyjcInspectionApplicationModel
>
queue
=
new
LinkedBlockingQueue
<>();
@Value
(
"${inspection.push.max.deal.thread.num:2}"
)
@Value
(
"${inspection.push.max.deal.thread.num:2}"
)
...
@@ -133,6 +140,7 @@ public class InspectionApplicationPushEventListener implements ApplicationListen
...
@@ -133,6 +140,7 @@ public class InspectionApplicationPushEventListener implements ApplicationListen
@PostConstruct
@PostConstruct
public
void
init
()
{
public
void
init
()
{
companyCodeRegNameMap
=
JsonUtils
.
getResourceJson
(
regNameJson
);
ExecutorService
executorService
=
Executors
.
newFixedThreadPool
(
threadNum
);
ExecutorService
executorService
=
Executors
.
newFixedThreadPool
(
threadNum
);
// 可处理的检验检测类型,目前只处理检验的,不处理检测业务
// 可处理的检验检测类型,目前只处理检验的,不处理检测业务
List
<
String
>
canDealInspectionTypes
=
getCanDealInspectionType
();
List
<
String
>
canDealInspectionTypes
=
getCanDealInspectionType
();
...
@@ -259,13 +267,14 @@ public class InspectionApplicationPushEventListener implements ApplicationListen
...
@@ -259,13 +267,14 @@ public class InspectionApplicationPushEventListener implements ApplicationListen
equipData
.
setUseCertFilePath
(
jgRegisterInfo
.
getLastUseCertFilePath
());
equipData
.
setUseCertFilePath
(
jgRegisterInfo
.
getLastUseCertFilePath
());
}
}
// 登记机关
// 登记机关
if
(
equipData
.
getUseRegistrationCode
()
!=
null
)
{
if
(
equipData
.
getUseRegistrationCode
()
!=
null
)
{
LambdaQueryWrapper
<
JgUseRegistrationManage
>
queryWrapper
=
new
LambdaQueryWrapper
<
JgUseRegistrationManage
>()
LambdaQueryWrapper
<
JgUseRegistrationManage
>
queryWrapper
=
new
LambdaQueryWrapper
<
JgUseRegistrationManage
>()
.
eq
(
JgUseRegistrationManage:
:
getUseRegistrationCode
,
equipData
.
getUseRegistrationCode
())
.
eq
(
JgUseRegistrationManage:
:
getUseRegistrationCode
,
equipData
.
getUseRegistrationCode
())
.
eq
(
JgUseRegistrationManage:
:
getIsDelete
,
0
).
select
(
JgUseRegistrationManage:
:
getRegUnitName
,
BaseEntity:
:
getSequenceNbr
);
.
eq
(
JgUseRegistrationManage:
:
getIsDelete
,
0
)
JgUseRegistrationManage
jgUseRegistrationManage
=
jgUseRegistrationManageMapper
.
selectOne
(
queryWrapper
);
.
select
(
JgUseRegistrationManage:
:
getReceiveCompanyCode
,
BaseEntity:
:
getSequenceNbr
);
if
(
jgUseRegistrationManage
!=
null
){
JgUseRegistrationManage
manage
=
jgUseRegistrationManageMapper
.
selectOne
(
queryWrapper
);
equipData
.
setRegUnitName
(
jgUseRegistrationManage
.
getRegUnitName
());
if
(
manage
!=
null
)
{
equipData
.
setRegUnitName
(
companyCodeRegNameMap
.
getOrDefault
(
manage
.
getReceiveCompanyCode
(),
manage
.
getReceiveOrgName
()));
}
}
}
}
}
}
...
...
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