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
4fd98308
Commit
4fd98308
authored
Apr 28, 2025
by
韩桐桐
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
安全追溯-企业问题状态修正;问题处理枚举调整
parent
613f16a7
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
35 additions
and
34 deletions
+35
-34
SafetyProblemTypeEnum.java
.../amos/boot/module/jg/api/enums/SafetyProblemTypeEnum.java
+21
-23
SafetyProblemTracingMapper.xml
.../src/main/resources/mapper/SafetyProblemTracingMapper.xml
+6
-6
EquipmentProblemStrategy.java
...ule/jg/biz/handler/strategy/EquipmentProblemStrategy.java
+5
-2
SafetyProblemTopicMessage.java
...oot/module/jg/biz/listener/SafetyProblemTopicMessage.java
+2
-2
SafetyProblemTracingGenServiceImpl.java
.../biz/service/impl/SafetyProblemTracingGenServiceImpl.java
+1
-1
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/enums/SafetyProblemTypeEnum.java
View file @
4fd98308
...
...
@@ -14,16 +14,24 @@ public enum SafetyProblemTypeEnum {
/**
* 问题类型枚举
*/
JYCQ
(
"2"
,
"检验超期"
,
"设备检验超期"
,
"safetyProblemTracing/jy/cq"
,
"outOfInspectionRecords"
),
JYBJ
(
"2
1
"
,
"检验报检"
,
"设备报检"
,
"safetyProblemTracing/jy/bj"
,
null
),
WBCQ
(
"1"
,
"维保超期"
,
"设备维保超期"
,
"safetyProblemTracing/wb/cq"
,
"outOfMaintenanceRecords"
),
WBBA
(
"
1
1"
,
"维保合同备案"
,
"设备维保合同备案"
,
"safetyProblemTracing/wb/ba"
,
null
),
XKCQ
(
"3"
,
"许可超期"
,
"企业许可超期"
,
"safetyProblemTracing/xk/cq"
,
null
),
ZZCQ
(
"9"
,
"资质超期"
,
"人员资质超期"
,
"safetyProblemTracing/zz/cq"
,
null
),
SJNXCQ
(
"5"
,
"超设计年限"
,
"设备超设计年限"
,
"safetyProblemTracing/synx/cq"
,
null
),
SJNXDJ
(
"
51
"
,
"超设计年限登记"
,
"超设计年限登记"
,
"safetyProblemTracing/synx/dj"
,
null
);
JYCQ
(
"
1"
,
"
2"
,
"检验超期"
,
"设备检验超期"
,
"safetyProblemTracing/jy/cq"
,
"outOfInspectionRecords"
),
JYBJ
(
"2
"
,
"2
"
,
"检验报检"
,
"设备报检"
,
"safetyProblemTracing/jy/bj"
,
null
),
WBCQ
(
"
3"
,
"
1"
,
"维保超期"
,
"设备维保超期"
,
"safetyProblemTracing/wb/cq"
,
"outOfMaintenanceRecords"
),
WBBA
(
"
4"
,
"
1"
,
"维保合同备案"
,
"设备维保合同备案"
,
"safetyProblemTracing/wb/ba"
,
null
),
XKCQ
(
"
5"
,
"
3"
,
"许可超期"
,
"企业许可超期"
,
"safetyProblemTracing/xk/cq"
,
null
),
ZZCQ
(
"
6"
,
"
9"
,
"资质超期"
,
"人员资质超期"
,
"safetyProblemTracing/zz/cq"
,
null
),
SJNXCQ
(
"
7"
,
"
5"
,
"超设计年限"
,
"设备超设计年限"
,
"safetyProblemTracing/synx/cq"
,
null
),
SJNXDJ
(
"
8"
,
"5
"
,
"超设计年限登记"
,
"超设计年限登记"
,
"safetyProblemTracing/synx/dj"
,
null
);
private
final
String
code
;
/**
* 数据主键
*/
private
final
String
sequenceNbr
;
/**
* 问题类型代码
*/
private
final
String
problemTypeCode
;
private
final
String
name
;
...
...
@@ -33,25 +41,15 @@ public enum SafetyProblemTypeEnum {
/**
* 消息对象属性
*
*
/
*/
private
final
String
msgKey
;
SafetyProblemTypeEnum
(
String
code
,
String
name
,
String
desc
,
String
topic
,
String
msgKey
)
{
this
.
code
=
code
;
SafetyProblemTypeEnum
(
String
sequenceNbr
,
String
problemTypeCode
,
String
name
,
String
desc
,
String
topic
,
String
msgKey
)
{
this
.
sequenceNbr
=
sequenceNbr
;
this
.
problemTypeCode
=
problemTypeCode
;
this
.
name
=
name
;
this
.
desc
=
desc
;
this
.
topic
=
topic
;
this
.
msgKey
=
msgKey
;
}
public
static
String
getNameByType
(
String
code
)
{
String
name
=
null
;
for
(
SafetyProblemTypeEnum
enumOne
:
SafetyProblemTypeEnum
.
values
())
{
if
(
enumOne
.
getCode
().
equals
(
code
))
{
name
=
enumOne
.
getName
();
break
;
}
}
return
name
;
}
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/SafetyProblemTracingMapper.xml
View file @
4fd98308
...
...
@@ -112,9 +112,9 @@
ei.use_contact useContact,
ei.contact_phone contactPhone,
ei.status,
case when ei.status = '
0
' then '异常'
case when ei.status = '
1
' then '异常'
else '正常' end problemStatusName,
case when ei.status = '
0
' then 'red'
case when ei.status = '
1
' then 'red'
else 'green' end problemStatusColor
FROM
tzs_safety_problem_tracing spt
...
...
@@ -133,9 +133,9 @@
ei.use_contact useContact,
ei.contact_phone contactPhone,
ei.status,
case when ei.status = '
0
' then '异常'
case when ei.status = '
1
' then '异常'
else '正常' end problemStatusName,
case when ei.status = '
0
' then 'red'
case when ei.status = '
1
' then 'red'
else 'green' end problemStatusColor
FROM
tzs_safety_problem_tracing spt
...
...
@@ -154,9 +154,9 @@
ei.use_contact useContact,
ei.contact_phone contactPhone,
ei.status,
case when ei.status = '
0
' then '异常'
case when ei.status = '
1
' then '异常'
else '正常' end problemStatusName,
case when ei.status = '
0
' then 'red'
case when ei.status = '
1
' then 'red'
else 'green' end problemStatusColor
FROM
tzs_safety_problem_tracing spt
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/handler/strategy/EquipmentProblemStrategy.java
View file @
4fd98308
...
...
@@ -16,7 +16,10 @@ import org.springframework.stereotype.Component;
import
org.springframework.transaction.annotation.Transactional
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
java.util.*
;
import
java.util.ArrayList
;
import
java.util.HashSet
;
import
java.util.List
;
import
java.util.Set
;
import
java.util.stream.Collectors
;
@Component
(
"equipmentProblemStrategy"
)
...
...
@@ -48,7 +51,7 @@ public class EquipmentProblemStrategy implements ProblemHandleStrategy {
.
set
(
SafetyProblemTracing:
:
getProblemStatusCode
,
SafetyProblemStatusEnum
.
HANDLED
.
getCode
())
.
set
(
SafetyProblemTracing:
:
getProblemStatus
,
SafetyProblemStatusEnum
.
HANDLED
.
getName
())
.
in
(
SafetyProblemTracing:
:
getSourceId
,
equipRecords
)
.
eq
(
SafetyProblemTracing:
:
getProblemTypeCode
,
problemTypeEnum
.
getCode
())
.
eq
(
SafetyProblemTracing:
:
getProblemTypeCode
,
problemTypeEnum
.
get
ProblemType
Code
())
.
update
();
// 查询仍存在未处理问题的设备
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/listener/SafetyProblemTopicMessage.java
View file @
4fd98308
...
...
@@ -122,7 +122,7 @@ public class SafetyProblemTopicMessage extends EmqxListener {
SafetyProblemTracing
safetyProblemTracing
=
new
SafetyProblemTracing
();
// safetyProblemTracing.setProblemNum(json.getString("problemNum"));
safetyProblemTracing
.
setProblemType
(
problemTypeEnum
.
getName
());
safetyProblemTracing
.
setProblemTypeCode
(
problemTypeEnum
.
getCode
());
safetyProblemTracing
.
setProblemTypeCode
(
problemTypeEnum
.
get
ProblemType
Code
());
safetyProblemTracing
.
setProblemDesc
(
problemTypeEnum
.
getDesc
());
// safetyProblemTracing.setProblemLevel(json.getString("problemLevel"));
// safetyProblemTracing.setProblemLevelCode(json.getString("problemLevelCode"));
...
...
@@ -173,7 +173,7 @@ public class SafetyProblemTopicMessage extends EmqxListener {
JSONObject
json
=
(
JSONObject
)
item
;
SafetyProblemTracing
safetyProblemTracing
=
new
SafetyProblemTracing
();
safetyProblemTracing
.
setProblemType
(
problemTypeEnum
.
getName
());
safetyProblemTracing
.
setProblemTypeCode
(
problemTypeEnum
.
getCode
());
safetyProblemTracing
.
setProblemTypeCode
(
problemTypeEnum
.
get
ProblemType
Code
());
safetyProblemTracing
.
setProblemDesc
(
json
.
getString
(
"problemDesc"
));
safetyProblemTracing
.
setSourceType
(
json
.
getString
(
"sourceType"
));
safetyProblemTracing
.
setSourceTypeCode
(
json
.
getString
(
"sourceTypeCode"
));
...
...
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/SafetyProblemTracingGenServiceImpl.java
View file @
4fd98308
...
...
@@ -127,7 +127,7 @@ public class SafetyProblemTracingGenServiceImpl{
.
set
(
SafetyProblemTracing:
:
getProblemStatusCode
,
SafetyProblemStatusEnum
.
HANDLED
.
getCode
())
.
set
(
SafetyProblemTracing:
:
getProblemStatus
,
SafetyProblemStatusEnum
.
HANDLED
.
getName
())
.
in
(
SafetyProblemTracing:
:
getSourceId
,
errorRecord
)
.
eq
(
SafetyProblemTracing:
:
getProblemTypeCode
,
SafetyProblemTypeEnum
.
WBCQ
.
getCode
())
.
eq
(
SafetyProblemTracing:
:
getProblemTypeCode
,
SafetyProblemTypeEnum
.
WBCQ
.
get
ProblemType
Code
())
.
eq
(
SafetyProblemTracing:
:
getIsDelete
,
Boolean
.
FALSE
)
.
update
();
idxBizJgOtherInfoService
.
lambdaUpdate
().
set
(
IdxBizJgOtherInfo:
:
getStatus
,
null
)
...
...
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