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
88de4d5f
Commit
88de4d5f
authored
Jul 17, 2025
by
刘林
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/develop_tzs_register' into develop_tzs_register
parents
f5a9b5e7
99ee543e
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
49 additions
and
4 deletions
+49
-4
DPStatusEnum.java
...n/amos/boot/module/statistics/api/enums/DPStatusEnum.java
+14
-1
DPSubServiceImpl.java
...t/module/statistcs/biz/service/impl/DPSubServiceImpl.java
+30
-0
JGDPStatisticsServiceImpl.java
...statistcs/biz/service/impl/JGDPStatisticsServiceImpl.java
+3
-0
StCommonServiceImpl.java
...odule/statistcs/biz/service/impl/StCommonServiceImpl.java
+2
-3
No files found.
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-api/src/main/java/com/yeejoin/amos/boot/module/statistics/api/enums/DPStatusEnum.java
View file @
88de4d5f
...
@@ -31,7 +31,11 @@ public enum DPStatusEnum {
...
@@ -31,7 +31,11 @@ public enum DPStatusEnum {
MANAGE_STATUS_OPEN
(
"manageOpen"
,
"在业"
,
"开业"
,
""
,
"success"
),
MANAGE_STATUS_OPEN
(
"manageOpen"
,
"在业"
,
"开业"
,
""
,
"success"
),
MANAGE_STATUS_STOP
(
"manageStop"
,
"停业"
,
"停业"
,
""
,
"error"
),
MANAGE_STATUS_STOP
(
"manageStop"
,
"停业"
,
"停业"
,
""
,
"error"
),
COMPANY_EMPHASIS_MONITOR
(
"emphasisMonitorCompany"
,
"重点监控企业"
,
"重点监控企业"
,
""
,
"success"
),
COMPANY_EMPHASIS_MONITOR
(
"emphasisMonitorCompany"
,
"重点监控企业"
,
"重点监控企业"
,
""
,
"success"
),
COMPANY_HIGH_RISK
(
"highRisk"
,
"高风险企业"
,
"高风险企业"
,
""
,
"stop"
);
COMPANY_HIGH_RISK
(
"highRisk"
,
"高风险企业"
,
"高风险企业"
,
""
,
"stop"
),
EQUIP_DATA_QUALITY_SCORE_1
(
"1"
,
"一类"
,
"一类"
,
""
,
"success"
),
EQUIP_DATA_QUALITY_SCORE_2
(
"2"
,
"二类"
,
"二类"
,
""
,
"success"
),
EQUIP_DATA_QUALITY_SCORE_3
(
"3"
,
"三类"
,
"三类"
,
""
,
"success"
);
private
String
key
;
private
String
key
;
private
String
label
;
private
String
label
;
...
@@ -48,6 +52,15 @@ public enum DPStatusEnum {
...
@@ -48,6 +52,15 @@ public enum DPStatusEnum {
return
null
;
return
null
;
}
}
public
static
DPStatusEnum
getEnumByKey
(
String
key
)
{
for
(
DPStatusEnum
c
:
DPStatusEnum
.
values
())
{
if
(
c
.
getKey
().
equals
(
key
)){
return
c
;
}
}
return
null
;
}
public
static
Map
toMap
(
DPStatusEnum
dpStatusEnum
)
{
public
static
Map
toMap
(
DPStatusEnum
dpStatusEnum
)
{
Map
map
=
new
HashMap
<>();
Map
map
=
new
HashMap
<>();
map
.
put
(
"key"
,
dpStatusEnum
.
getKey
());
map
.
put
(
"key"
,
dpStatusEnum
.
getKey
());
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/service/impl/DPSubServiceImpl.java
View file @
88de4d5f
...
@@ -266,6 +266,7 @@ public class DPSubServiceImpl {
...
@@ -266,6 +266,7 @@ public class DPSubServiceImpl {
// 处理标签
// 处理标签
JSONArray
status
=
(
JSONArray
)
JsonValueUtils
.
getValueByKey
(
content
,
"keyinfo"
,
"keyinfo.status"
);
JSONArray
status
=
(
JSONArray
)
JsonValueUtils
.
getValueByKey
(
content
,
"keyinfo"
,
"keyinfo.status"
);
this
.
processLabel
(
status
,
param
.
getString
(
"EQU_STATE"
));
this
.
processLabel
(
status
,
param
.
getString
(
"EQU_STATE"
));
this
.
processLabelByKey
(
status
,
param
.
getString
(
"DATA_QUALITY_SCORE"
));
// 处理问题列表
// 处理问题列表
List
<
Map
<
String
,
String
>>
problem
=
dpSubBizService
.
queryProblemListBySourceId
(
param
.
getString
(
"record"
));
List
<
Map
<
String
,
String
>>
problem
=
dpSubBizService
.
queryProblemListBySourceId
(
param
.
getString
(
"record"
));
...
@@ -306,6 +307,7 @@ public class DPSubServiceImpl {
...
@@ -306,6 +307,7 @@ public class DPSubServiceImpl {
JSONArray
status
=
(
JSONArray
)
JsonValueUtils
.
getValueByKey
(
content
,
"keyinfo"
,
"keyinfo.status"
);
JSONArray
status
=
(
JSONArray
)
JsonValueUtils
.
getValueByKey
(
content
,
"keyinfo"
,
"keyinfo.status"
);
this
.
processLabel
(
status
,
result
.
getString
(
"unitType"
));
this
.
processLabel
(
status
,
result
.
getString
(
"unitType"
));
this
.
processLabel
(
status
,
result
.
getString
(
"operatingStatus"
));
this
.
processLabel
(
status
,
result
.
getString
(
"operatingStatus"
));
this
.
processRegulatoryLabels
(
status
,
result
.
getString
(
"regulatoryLabels"
));
// 处理问题列表
// 处理问题列表
List
<
Map
<
String
,
String
>>
problem
=
dpSubBizService
.
queryProblemListBySourceId
(
param
.
getString
(
"sequenceNbr"
));
List
<
Map
<
String
,
String
>>
problem
=
dpSubBizService
.
queryProblemListBySourceId
(
param
.
getString
(
"sequenceNbr"
));
if
(!
ValidationUtil
.
isEmpty
(
problem
)){
if
(!
ValidationUtil
.
isEmpty
(
problem
)){
...
@@ -344,6 +346,34 @@ public class DPSubServiceImpl {
...
@@ -344,6 +346,34 @@ public class DPSubServiceImpl {
return
status
;
return
status
;
}
}
private
JSONArray
processRegulatoryLabels
(
JSONArray
status
,
String
labels
){
if
(!
ValidationUtil
.
isEmpty
(
labels
)){
int
i
=
0
;
for
(
String
label
:
labels
.
split
(
","
)){
i
++;
Map
map
=
new
HashMap
<>();
map
.
put
(
"key"
,
i
);
map
.
put
(
"label"
,
label
);
map
.
put
(
"status"
,
label
);
map
.
put
(
"icon"
,
""
);
map
.
put
(
"value"
,
"success"
);
status
.
add
(
map
);
}
}
return
status
;
}
private
JSONArray
processLabelByKey
(
JSONArray
status
,
String
key
){
if
(!
ValidationUtil
.
isEmpty
(
key
)){
DPStatusEnum
enumByStatus
=
DPStatusEnum
.
getEnumByKey
(
key
);
if
(!
ValidationUtil
.
isEmpty
(
enumByStatus
)){
status
.
add
(
DPStatusEnum
.
toMap
(
enumByStatus
));
}
}
return
status
;
}
private
JSONArray
processShowHideRules
(
JSONArray
children
,
Object
showHideRules
,
Object
apiResult
)
{
private
JSONArray
processShowHideRules
(
JSONArray
children
,
Object
showHideRules
,
Object
apiResult
)
{
JSONObject
result
=
JSONObject
.
parseObject
(
apiResult
.
toString
());
JSONObject
result
=
JSONObject
.
parseObject
(
apiResult
.
toString
());
Map
<
String
,
String
>
relationMap
=
new
HashMap
<>();
Map
<
String
,
String
>
relationMap
=
new
HashMap
<>();
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/service/impl/JGDPStatisticsServiceImpl.java
View file @
88de4d5f
...
@@ -380,6 +380,9 @@ public class JGDPStatisticsServiceImpl {
...
@@ -380,6 +380,9 @@ public class JGDPStatisticsServiceImpl {
long
cylinderNum
=
stCommonService
.
staticsCenterMapCountDataForCylinder
(
result
,
orgCode
,
true
,
false
,
false
);
long
cylinderNum
=
stCommonService
.
staticsCenterMapCountDataForCylinder
(
result
,
orgCode
,
true
,
false
,
false
);
//1.8大类设备数量统计,压力容器里包括气瓶所以需要特殊处理,在统计压力容器时去掉气瓶的数量
//1.8大类设备数量统计,压力容器里包括气瓶所以需要特殊处理,在统计压力容器时去掉气瓶的数量
stCommonService
.
staticsCenterMapCountDataForEquip
(
result
,
cylinderNum
,
orgCode
,
true
,
false
,
false
);
stCommonService
.
staticsCenterMapCountDataForEquip
(
result
,
cylinderNum
,
orgCode
,
true
,
false
,
false
);
// 单独计算已纳管设备(台套)数量总数
long
hasSupervisoryCodeEquipCount
=
stCommonService
.
queryHasSupervisoryCodeEquipCount
(
orgCode
,
false
);
result
.
put
(
"total"
,
hasSupervisoryCodeEquipCount
);
//2.压力管道长度统计
//2.压力管道长度统计
stCommonService
.
staticsCenterMapCountDataForPipeline
(
result
,
orgCode
,
true
,
false
);
stCommonService
.
staticsCenterMapCountDataForPipeline
(
result
,
orgCode
,
true
,
false
);
//3.单位数量统计
//3.单位数量统计
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/service/impl/StCommonServiceImpl.java
View file @
88de4d5f
...
@@ -303,7 +303,7 @@ public class StCommonServiceImpl {
...
@@ -303,7 +303,7 @@ public class StCommonServiceImpl {
});
});
// 注意,求总数时:countMap不包括气瓶数量、压力管道数量(20240819修改)
// 注意,求总数时:countMap不包括气瓶数量、压力管道数量(20240819修改)
// 总数为已赋码设备数量,需要单独统计
// 总数为已赋码设备数量,需要单独统计
result
.
put
(
DPMapStatisticsItemEnum
.
TOTAL
.
getCode
(),
queryHasSupervisoryCodeEquipCount
(
orgCode
,
isOrgBranchCodeExactMatch
,
cylinderNum
));
result
.
put
(
DPMapStatisticsItemEnum
.
TOTAL
.
getCode
(),
countMap
.
values
().
stream
().
mapToLong
(
e
->
e
).
sum
(
));
}
catch
(
IOException
e
)
{
}
catch
(
IOException
e
)
{
throw
new
RuntimeException
(
e
);
throw
new
RuntimeException
(
e
);
}
}
...
@@ -315,10 +315,9 @@ public class StCommonServiceImpl {
...
@@ -315,10 +315,9 @@ public class StCommonServiceImpl {
* 统计已赋码设备数量
* 统计已赋码设备数量
* @param orgCode
* @param orgCode
* @param isOrgBranchCodeExactMatch
* @param isOrgBranchCodeExactMatch
* @param cylinderNum
* @return
* @return
*/
*/
public
long
queryHasSupervisoryCodeEquipCount
(
String
orgCode
,
Boolean
isOrgBranchCodeExactMatch
,
long
cylinderNum
)
{
public
long
queryHasSupervisoryCodeEquipCount
(
String
orgCode
,
Boolean
isOrgBranchCodeExactMatch
)
{
CountRequest
request
=
new
CountRequest
();
CountRequest
request
=
new
CountRequest
();
request
.
indices
(
"idx_biz_view_jg_all"
);
request
.
indices
(
"idx_biz_view_jg_all"
);
BoolQueryBuilder
boolMust
=
QueryBuilders
.
boolQuery
();
BoolQueryBuilder
boolMust
=
QueryBuilders
.
boolQuery
();
...
...
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