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
e83f1f3e
Commit
e83f1f3e
authored
Oct 31, 2025
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(jg): 压力管道管道长度
1.压力管道新设备导入自测联调修改
parent
deecf65c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
17 deletions
+9
-17
DataDockServiceImpl.java
.../boot/module/jg/biz/service/impl/DataDockServiceImpl.java
+9
-17
No files found.
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/DataDockServiceImpl.java
View file @
e83f1f3e
...
...
@@ -38,6 +38,7 @@ import com.yeejoin.amos.boot.module.jg.api.mapper.*;
import
com.yeejoin.amos.boot.module.jg.biz.config.LocalBadRequest
;
import
com.yeejoin.amos.boot.module.jg.biz.context.EquipUsedCheckStrategyContext
;
import
com.yeejoin.amos.boot.module.jg.biz.context.FlowingEquipRedisContext
;
import
com.yeejoin.amos.boot.module.jg.biz.edit.process.equip.PieLineDataChangeServiceImpl
;
import
com.yeejoin.amos.boot.module.jg.biz.event.publisher.EventPublisher
;
import
com.yeejoin.amos.boot.module.jg.biz.feign.TzsServiceFeignClient
;
import
com.yeejoin.amos.boot.module.jg.biz.reminder.core.event.EquipCreateOrEditEvent
;
...
...
@@ -163,6 +164,8 @@ public class DataDockServiceImpl {
private
final
IdxBizJgOtherInfoMapper
idxBizJgOtherInfoMapper
;
private
final
IdxBizJgInspectionDetectionInfoMapper
idxBizJgInspectionDetectionInfoMapper
;
private
final
PieLineDataChangeServiceImpl
pieLineDataChangeService
;
@Value
(
"${equip.detail.path:/mixuap?appId=1742358052905971713&id=1734100233714954241&formType=detail&record=%s&DATA_SOURCE=%s}"
)
private
String
equipRoutePath
;
...
...
@@ -325,18 +328,12 @@ public class DataDockServiceImpl {
projectContraption
.
setEquCategoryName
(
EquCategoryConverter
.
getKeyByValue
((
String
)
equ
.
get
(
"equCategory"
)));
projectContraption
.
setEquDefine
((
String
)
equ
.
get
(
"equDefine"
));
projectContraption
.
setEquDefineName
(
EquDefineConverter
.
getKeyByValue
((
String
)
equ
.
get
(
"equDefine"
)));
projectContraption
.
setPipelineLength
(
new
BigDecimal
(
Objects
.
toString
(
equ
.
get
(
"totalPipeLength"
),
"0"
)).
doubleValue
());
projectContraption
.
setUseRegistrationCode
((
String
)
equ
.
get
(
"useOrgCode"
));
projectContraption
.
setIsIntoManagement
(
Boolean
.
FALSE
);
projectContraption
.
setDataSource
(
dataSource
);
idxBizJgProjectContraptionService
.
save
(
projectContraption
);
}
else
{
// update
}
else
{
sequenceNbr
=
oldContraption
.
getSequenceNbr
();
Double
oldPipelineLength
=
oldContraption
.
getPipelineLength
();
UpdateWrapper
<
IdxBizJgProjectContraption
>
updateWrapper
=
new
UpdateWrapper
<>();
updateWrapper
.
eq
(
"sequence_nbr"
,
oldContraption
.
getSequenceNbr
())
// 根据主键更新
.
set
(
"pipeline_length"
,
Double
.
sum
(
oldPipelineLength
,
Double
.
parseDouble
((
String
)
equ
.
get
(
"pipeLength"
))));
idxBizJgProjectContraptionService
.
update
(
updateWrapper
);
}
}
}
...
...
@@ -1574,14 +1571,6 @@ public class DataDockServiceImpl {
Set
<
String
>
recordSet
=
new
HashSet
<>();
Set
<
String
>
projectContraptionSet
=
new
HashSet
<>();
Map
<
String
,
Long
>
projectContraptionMap
=
new
HashMap
<>();
Map
<
String
,
BigDecimal
>
pipeLengthMap
=
equipInfoExcelDtos
.
stream
()
.
collect
(
Collectors
.
groupingBy
(
e
->
Objects
.
toString
(
e
.
getProjectContraptionNo
(),
""
).
trim
(),
Collectors
.
mapping
(
e
->
PipLenCalUtils
.
calBigDecimal
(
e
.
getPipeLength
()),
Collectors
.
reducing
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
)
)
));
Set
<
String
>
projectContraptionIdSet
=
new
HashSet
<>();
for
(
EquipInfoExcelDto
equ
:
equipInfoExcelDtos
)
{
List
<
Map
<
String
,
Object
>>
fileDataList
=
(
List
<
Map
<
String
,
Object
>>)
equ
.
getFileData
();
...
...
@@ -1597,8 +1586,6 @@ public class DataDockServiceImpl {
String
projectContraptionNo
=
Objects
.
toString
(
equMap
.
get
(
"projectContraptionNo"
),
""
).
trim
();
Long
projectContraptionId
;
if
(!
projectContraptionSet
.
contains
(
projectContraptionNo
))
{
BigDecimal
totalPipeLength
=
pipeLengthMap
.
getOrDefault
(
projectContraptionNo
,
BigDecimal
.
ZERO
);
equMap
.
put
(
"totalPipeLength"
,
totalPipeLength
);
projectContraptionId
=
this
.
saveProjectContraption
(
equMap
,
equList
,
company
,
dataSource
);
projectContraptionSet
.
add
(
projectContraptionNo
);
projectContraptionMap
.
put
(
projectContraptionNo
,
projectContraptionId
);
...
...
@@ -1613,6 +1600,7 @@ public class DataDockServiceImpl {
recordSet
.
add
(
record
);
}
if
(
EquipmentClassifityEnum
.
YLGD
.
getCode
().
equals
(
equList
))
{
this
.
updatePipelineLength
(
projectContraptionIdSet
);
this
.
createResumePipelineBatch
(
projectContraptionIdSet
,
String
.
format
(
pipelineRoutePath
,
projectContraptionIdSet
),
company
);
eventPublisher
.
publish
(
new
EquipCreateOrEditEvent
(
this
,
BusinessTypeEnum
.
JG_NEW_PROJECT
.
name
(),
projectContraptionIdSet
,
EquipCreateOrEditEvent
.
EquipType
.
project
));
}
else
{
...
...
@@ -1621,6 +1609,10 @@ public class DataDockServiceImpl {
}
}
private
void
updatePipelineLength
(
Set
<
String
>
projectContraptionIdSet
)
{
projectContraptionIdSet
.
forEach
(
pieLineDataChangeService:
:
updatePipelineLength
);
}
private
void
createResumeBatch
(
Set
<
String
>
records
,
String
dataSource
,
String
routePath
,
CompanyBo
company
)
{
jgResumeInfoService
.
saveBatchResume
(
records
.
stream
().
map
(
record
->
JgResumeInfoDto
.
builder
()
.
businessType
(
BusinessTypeEnum
.
JG_NEW_EQUIP
.
getName
())
...
...
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