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
e40fd9a0
Commit
e40fd9a0
authored
Aug 27, 2025
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(jg): 设备业务履历
1.设备导入、装置导入
parent
ac382516
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
57 additions
and
3 deletions
+57
-3
DataDockController.java
...mos/boot/module/jg/biz/controller/DataDockController.java
+3
-2
DataDockServiceImpl.java
.../boot/module/jg/biz/service/impl/DataDockServiceImpl.java
+38
-1
IdxBizJgRegisterInfoServiceImpl.java
.../jg/biz/service/impl/IdxBizJgRegisterInfoServiceImpl.java
+16
-0
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/controller/DataDockController.java
View file @
e40fd9a0
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
biz
.
controller
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
biz
.
controller
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.module.jg.biz.service.impl.DataDockServiceImpl
;
import
com.yeejoin.amos.boot.module.jg.biz.service.impl.DataDockServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
...
@@ -20,7 +21,7 @@ import java.util.Map;
...
@@ -20,7 +21,7 @@ import java.util.Map;
@RestController
@RestController
@Api
(
tags
=
"数据对接 API"
)
@Api
(
tags
=
"数据对接 API"
)
@RequestMapping
(
value
=
"/dataDock"
)
@RequestMapping
(
value
=
"/dataDock"
)
public
class
DataDockController
{
public
class
DataDockController
extends
BaseController
{
private
final
DataDockServiceImpl
dataDockService
;
private
final
DataDockServiceImpl
dataDockService
;
...
@@ -158,7 +159,7 @@ public class DataDockController {
...
@@ -158,7 +159,7 @@ public class DataDockController {
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"工业 、公用、长输管道批量保存"
,
notes
=
"工业 、公用、长输管道批量保存"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"工业 、公用、长输管道批量保存"
,
notes
=
"工业 、公用、长输管道批量保存"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<?>
savePipingData
(
@RequestBody
Map
<
String
,
Object
>
paramMap
)
{
public
ResponseModel
<?>
savePipingData
(
@RequestBody
Map
<
String
,
Object
>
paramMap
)
{
return
ResponseHelper
.
buildResponse
(
dataDockService
.
savePipingData
(
paramMap
));
return
ResponseHelper
.
buildResponse
(
dataDockService
.
savePipingData
(
paramMap
,
getSelectedOrgInfo
().
getCompany
()
));
}
}
/**
/**
...
...
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 @
e40fd9a0
...
@@ -161,6 +161,12 @@ public class DataDockServiceImpl {
...
@@ -161,6 +161,12 @@ public class DataDockServiceImpl {
private
final
IdxBizJgOtherInfoMapper
idxBizJgOtherInfoMapper
;
private
final
IdxBizJgOtherInfoMapper
idxBizJgOtherInfoMapper
;
private
final
IdxBizJgInspectionDetectionInfoMapper
idxBizJgInspectionDetectionInfoMapper
;
private
final
IdxBizJgInspectionDetectionInfoMapper
idxBizJgInspectionDetectionInfoMapper
;
@Value
(
"${equip.detail.path:/mixuap?appId=1742358052905971713&id=1734100233714954241&formType=detail&record=%s&DATA_SOURCE=%s}"
)
private
String
equipRoutePath
;
@Value
(
"${pipeline.detail.path:/mixuap?appId=1742358052905971713&id=1867406434120003586&formType=detail&sequenceNbr=%s}"
)
private
String
pipelineRoutePath
;
/**
/**
* 西安数据对接-保存设备信息
* 西安数据对接-保存设备信息
*
*
...
@@ -1583,6 +1589,7 @@ public class DataDockServiceImpl {
...
@@ -1583,6 +1589,7 @@ public class DataDockServiceImpl {
String
record
=
saveEquipmentDataInTransaction
(
equMap
,
dataSource
,
remark
);
String
record
=
saveEquipmentDataInTransaction
(
equMap
,
dataSource
,
remark
);
recordSet
.
add
(
record
);
recordSet
.
add
(
record
);
}
}
this
.
createResumeBatch
(
recordSet
,
dataSource
,
equipRoutePath
,
company
);
eventPublisher
.
publish
(
new
EquipCreateOrEditEvent
(
eventPublisher
.
publish
(
new
EquipCreateOrEditEvent
(
this
,
this
,
BusinessTypeEnum
.
JG_NEW_EQUIP
.
name
(),
BusinessTypeEnum
.
JG_NEW_EQUIP
.
name
(),
...
@@ -1591,6 +1598,21 @@ public class DataDockServiceImpl {
...
@@ -1591,6 +1598,21 @@ public class DataDockServiceImpl {
));
));
}
}
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
())
.
businessId
(
record
)
.
equId
(
record
)
.
status
(
"正常"
)
.
approvalUnitCode
(
company
.
getCompanyCode
())
.
approvalUnit
(
company
.
getCompanyName
())
.
changeContent
(
BusinessTypeEnum
.
JG_NEW_EQUIP
.
getName
()
+
"业务办理"
)
.
routePath
(
String
.
format
(
routePath
,
record
,
dataSource
))
.
build
()).
collect
(
Collectors
.
toList
())
);
}
/**
/**
* 批量异步保存设备数据
* 批量异步保存设备数据
*
*
...
@@ -1770,7 +1792,7 @@ public class DataDockServiceImpl {
...
@@ -1770,7 +1792,7 @@ public class DataDockServiceImpl {
}
}
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
public
Object
savePipingData
(
Map
<
String
,
Object
>
paramMap
)
{
public
Object
savePipingData
(
Map
<
String
,
Object
>
paramMap
,
CompanyBo
company
)
{
// 获取数据
// 获取数据
JSONObject
equipInfo
=
JSON
.
parseObject
(
toJSONString
(
paramMap
.
get
(
"equipInfo"
)),
JSONObject
.
class
);
JSONObject
equipInfo
=
JSON
.
parseObject
(
toJSONString
(
paramMap
.
get
(
"equipInfo"
)),
JSONObject
.
class
);
JSONObject
attachmentUpload
=
JSON
.
parseObject
(
toJSONString
(
paramMap
.
get
(
"attachmentUpload"
)),
JSONObject
.
class
);
JSONObject
attachmentUpload
=
JSON
.
parseObject
(
toJSONString
(
paramMap
.
get
(
"attachmentUpload"
)),
JSONObject
.
class
);
...
@@ -1836,10 +1858,25 @@ public class DataDockServiceImpl {
...
@@ -1836,10 +1858,25 @@ public class DataDockServiceImpl {
}
}
}
}
}
}
this
.
createResumePipeline
(
proCon
.
getSequenceNbr
(),
String
.
format
(
pipelineRoutePath
,
proCon
.
getSequenceNbr
()
+
""
),
company
);
eventPublisher
.
publish
(
new
EquipCreateOrEditEvent
(
this
,
BusinessTypeEnum
.
JG_NEW_PROJECT
.
name
(),
Sets
.
newHashSet
(
proCon
.
getSequenceNbr
()
+
""
),
EquipCreateOrEditEvent
.
EquipType
.
project
));
eventPublisher
.
publish
(
new
EquipCreateOrEditEvent
(
this
,
BusinessTypeEnum
.
JG_NEW_PROJECT
.
name
(),
Sets
.
newHashSet
(
proCon
.
getSequenceNbr
()
+
""
),
EquipCreateOrEditEvent
.
EquipType
.
project
));
return
Boolean
.
TRUE
;
return
Boolean
.
TRUE
;
}
}
private
void
createResumePipeline
(
Long
sequenceNbr
,
String
routePath
,
CompanyBo
company
)
{
jgResumeInfoService
.
saveBatchResume
(
Collections
.
singletonList
(
JgResumeInfoDto
.
builder
()
.
businessType
(
BusinessTypeEnum
.
JG_NEW_PROJECT
.
getName
())
.
businessId
(
sequenceNbr
+
""
)
.
equId
(
sequenceNbr
+
""
)
.
status
(
"正常"
)
.
approvalUnitCode
(
company
.
getCompanyCode
())
.
approvalUnit
(
company
.
getCompanyName
())
.
changeContent
(
BusinessTypeEnum
.
JG_NEW_PROJECT
.
getName
()
+
"业务办理"
)
.
routePath
(
routePath
)
.
build
())
);
}
public
void
saveCertChangeRecord
(
JgUseRegistration
useReg
,
JgUseRegistrationManage
regManage
,
List
<
String
>
records
,
EquipRequestParamsDto
paramsDto
)
{
public
void
saveCertChangeRecord
(
JgUseRegistration
useReg
,
JgUseRegistrationManage
regManage
,
List
<
String
>
records
,
EquipRequestParamsDto
paramsDto
)
{
Long
changeRecordId
=
sequence
.
nextId
();
Long
changeRecordId
=
sequence
.
nextId
();
JgCertificateChangeRecord
changeRecord
=
new
JgCertificateChangeRecord
()
JgCertificateChangeRecord
changeRecord
=
new
JgCertificateChangeRecord
()
...
...
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/IdxBizJgRegisterInfoServiceImpl.java
View file @
e40fd9a0
...
@@ -4522,6 +4522,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -4522,6 +4522,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
.
put
(
"nextInspectDate"
,
nextInspectDateStr
)
.
put
(
"nextInspectDate"
,
nextInspectDateStr
)
.
put
(
"useInnerCode"
,
useInfo
.
getUseInnerCode
())
.
put
(
"useInnerCode"
,
useInfo
.
getUseInnerCode
())
.
put
(
"informationSituation"
,
data
.
getInformationSituation
())
.
put
(
"informationSituation"
,
data
.
getInformationSituation
())
.
put
(
"dataSource"
,
useInfo
.
getDataSource
())
.
build
();
.
build
();
equipmentLists
.
add
(
equipMap
);
equipmentLists
.
add
(
equipMap
);
});
});
...
@@ -4611,6 +4612,21 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -4611,6 +4612,21 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
.
build
())
.
build
())
.
collect
(
Collectors
.
toList
())
.
collect
(
Collectors
.
toList
())
);
);
}
else
{
jgResumeInfoService
.
saveBatchResume
(
equipmentLists
.
stream
()
.
map
(
equipId
->
JgResumeInfoDto
.
builder
()
.
businessType
(
BusinessTypeEnum
.
JG_NEW_EQUIP
.
getName
())
.
businessId
(
String
.
valueOf
(
equipId
.
get
(
"record"
)))
.
equId
(
String
.
valueOf
(
equipId
.
get
(
"record"
)))
.
approvalUnit
(
reginParams
.
getCompany
().
getCompanyName
())
.
approvalUnitCode
(
reginParams
.
getCompany
().
getCompanyCode
())
.
status
(
"正常"
)
.
changeContent
(
BusinessTypeEnum
.
JG_NEW_EQUIP
.
getName
()
+
"业务办理"
)
.
routePath
(
String
.
format
(
equipRoutePath
,
equipId
.
get
(
"record"
),
equipId
.
get
(
"dataSource"
)))
.
build
())
.
collect
(
Collectors
.
toList
())
);
}
}
List
<
CompletableFuture
<
Void
>>
futures
=
new
ArrayList
<>();
List
<
CompletableFuture
<
Void
>>
futures
=
new
ArrayList
<>();
futures
.
add
(
CompletableFuture
.
runAsync
(()
->
futures
.
add
(
CompletableFuture
.
runAsync
(()
->
...
...
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