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
e0873d9f
Commit
e0873d9f
authored
Apr 25, 2025
by
刘林
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(jg):西安属地导入更新
parent
4d2149c8
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
94 additions
and
4 deletions
+94
-4
XiAnElevatorExcelDto.java
...om/yeejoin/amos/api/openapi/dto/XiAnElevatorExcelDto.java
+17
-0
XiAnDataDockServiceImpl.java
...oin/amos/api/openapi/service/XiAnDataDockServiceImpl.java
+7
-1
DataDockServiceImpl.java
.../boot/module/jg/biz/service/impl/DataDockServiceImpl.java
+69
-3
JgUseRegistrationServiceImpl.java
...ule/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
+1
-0
No files found.
amos-boot-data/amos-boot-data-openapi/src/main/java/com/yeejoin/amos/api/openapi/dto/XiAnElevatorExcelDto.java
View file @
e0873d9f
...
...
@@ -388,4 +388,20 @@ public class XiAnElevatorExcelDto extends BaseDto {
@ApiModelProperty
(
value
=
"电梯状态"
)
@ExcelProperty
(
value
=
"电梯状态"
,
converter
=
EquStateConverter
.
class
)
private
String
equState
;
@ApiModelProperty
(
value
=
"所属辖区"
)
@ExcelProperty
(
value
=
"所属辖区"
)
private
String
supervisionDepartment
;
@ApiModelProperty
(
value
=
"所属辖区代码"
)
@ExcelProperty
(
value
=
"所属辖区代码"
)
private
String
supervisionDepartmentCode
;
@ApiModelProperty
(
value
=
"市场监管所"
)
@ExcelProperty
(
value
=
"市场监管所"
)
private
String
supervisionOffice
;
@ApiModelProperty
(
value
=
"市场监管所代码"
)
@ExcelProperty
(
value
=
"市场监管所代码"
)
private
String
supervisionOfficeCode
;
}
\ No newline at end of file
amos-boot-data/amos-boot-data-openapi/src/main/java/com/yeejoin/amos/api/openapi/service/XiAnDataDockServiceImpl.java
View file @
e0873d9f
...
...
@@ -640,8 +640,10 @@ public class XiAnDataDockServiceImpl {
log
.
info
(
"解析第{}行数据:{}"
,
rowIndex
,
JSON
.
toJSONString
(
data
));
if
(
data
.
getEquList
()
!=
null
&&
!
data
.
getEquList
().
isEmpty
())
{
checkCommonInfo
(
data
,
rowError
);
}
else
{
}
else
if
(
data
.
getBusinessId
()
!=
null
&&
!
data
.
getBusinessId
().
isEmpty
())
{
checkResumeInfo
(
data
,
rowError
);
}
else
{
checkSupervisionInfo
(
data
,
rowError
);
}
data
.
setIsCompleteXa
(
1
);
if
(!
StringUtils
.
isBlank
(
rowError
))
{
...
...
@@ -653,6 +655,10 @@ public class XiAnDataDockServiceImpl {
}
}
private
void
checkSupervisionInfo
(
XiAnElevatorExcelDto
data
,
StringBuffer
rowError
)
{
checkNotBlank
(
data
.
getRecord
(),
"注册代码不能为空;"
,
rowError
);
}
private
void
checkResumeInfo
(
XiAnElevatorExcelDto
data
,
StringBuffer
rowError
)
{
checkNotBlank
(
data
.
getResumeSeq
(),
"监管履历主键不能为空;"
,
rowError
);
checkNotBlank
(
data
.
getBusinessType
(),
"业务类型不能为空;"
,
rowError
);
...
...
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 @
e0873d9f
...
...
@@ -14,6 +14,8 @@ import com.alibaba.fastjson.JSONArray;
import
com.alibaba.fastjson.JSONObject
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper
;
import
com.google.common.collect.Lists
;
import
com.yeejoin.amos.boot.biz.common.bo.CompanyBo
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.biz.common.utils.DateUtils
;
...
...
@@ -2202,6 +2204,7 @@ public class DataDockServiceImpl {
public
void
saveElevatorDataInTransaction
(
Map
<
String
,
Object
>
equ
,
String
dataSource
,
String
remark
)
{
String
record
=
Optional
.
ofNullable
(
equ
.
get
(
"record"
)).
map
(
String:
:
valueOf
).
orElse
(
UUID
.
randomUUID
().
toString
());
String
equList
=
Optional
.
ofNullable
(
equ
.
get
(
"equList"
)).
map
(
String:
:
valueOf
).
orElse
(
""
);
String
businessId
=
Optional
.
ofNullable
(
equ
.
get
(
"businessId"
)).
map
(
String:
:
valueOf
).
orElse
(
""
);
String
isCompleteXa
=
Optional
.
ofNullable
(
equ
.
get
(
"isCompleteXa"
)).
map
(
String:
:
valueOf
).
orElse
(
""
);
String
useRegistrationCode
=
Optional
.
ofNullable
(
equ
.
get
(
"useOrgCode"
)).
map
(
String:
:
valueOf
).
orElse
(
""
).
trim
();
try
{
...
...
@@ -2220,14 +2223,20 @@ public class DataDockServiceImpl {
if
(!
useRegistrationCode
.
isEmpty
()){
this
.
handleHistoryEquip
(
equ
);
//历史登记
}
}
else
{
}
else
if
(!
businessId
.
isEmpty
())
{
this
.
saveResumeInfo
(
equ
);
equ
.
put
(
"record"
,
equ
.
get
(
"resumeSeq"
));
equ
.
put
(
"xaSerial"
,
equ
.
get
(
"resumeSeq"
));
}
else
{
String
orgBranchName
=
(
String
)
Optional
.
ofNullable
(
equ
.
get
(
"supervisionOffice"
))
.
orElseGet
(()
->
equ
.
get
(
"supervisionDepartment"
));
String
orgBranchCode
=
(
String
)
Optional
.
ofNullable
(
equ
.
get
(
"supervisionOfficeCode"
))
.
orElseGet
(()
->
equ
.
get
(
"supervisionDepartmentCode"
));
this
.
updateOrgBranchInfo
(
record
,
orgBranchName
,
orgBranchCode
);
}
}
catch
(
Exception
e
)
{
esEquipmentCategory
.
deleteById
(
record
);
superviseInfoMapper
.
deleteDataAll
(
Collections
.
singletonList
(
record
));
//
esEquipmentCategory.deleteById(record);
//
superviseInfoMapper.deleteDataAll(Collections.singletonList(record));
ExcelImportErrorLogDto
errorLogDto
=
JSON
.
parseObject
(
toJSONString
(
equ
),
ExcelImportErrorLogDto
.
class
);
errorLogDto
.
setErrorInfo
(
e
.
getMessage
());
excelImportErrorLogDao
.
save
(
errorLogDto
);
...
...
@@ -2237,6 +2246,54 @@ public class DataDockServiceImpl {
}
}
@GlobalTransactional
(
rollbackFor
=
Exception
.
class
)
public
void
updateOrgBranchInfo
(
String
record
,
String
orgBranchName
,
String
orgBranchCode
)
{
this
.
updateSupervisionInfo
(
record
,
orgBranchName
,
orgBranchCode
);
this
.
updateEsOrgBranch
(
record
,
orgBranchName
,
orgBranchCode
);
this
.
updateUseRegistrationInfo
(
record
,
orgBranchName
,
orgBranchCode
);
}
private
void
updateUseRegistrationInfo
(
String
record
,
String
orgBranchName
,
String
orgBranchCode
)
{
Optional
.
ofNullable
(
idxBizJgRegisterInfoMapper
.
selectOne
(
new
QueryWrapper
<
IdxBizJgRegisterInfo
>()
.
lambda
()
.
eq
(
IdxBizJgRegisterInfo:
:
getRecord
,
record
)
))
.
map
(
IdxBizJgRegisterInfo:
:
getUseOrgCode
)
.
ifPresent
(
useOrgCode
->
jgUseRegistrationManageService
.
update
(
new
LambdaUpdateWrapper
<
JgUseRegistrationManage
>()
.
set
(
JgUseRegistrationManage:
:
getSuperviseOrgCode
,
orgBranchCode
)
.
set
(
JgUseRegistrationManage:
:
getSuperviseOrgName
,
orgBranchName
)
.
eq
(
JgUseRegistrationManage:
:
getUseRegistrationCode
,
useOrgCode
)
.
eq
(
JgUseRegistrationManage:
:
getIsDoBusiness
,
0
)
));
Optional
.
ofNullable
(
jgRelationEquipMapper
.
selectOne
(
new
QueryWrapper
<
JgUseRegistrationEq
>()
.
lambda
()
.
eq
(
JgUseRegistrationEq:
:
getEquId
,
record
)
.
eq
(
JgUseRegistrationEq:
:
getIsDelete
,
false
)
))
.
map
(
JgUseRegistrationEq:
:
getEquipTransferId
)
.
ifPresent
(
equipTransferId
->
jgUseRegistrationServiceImpl
.
update
(
new
LambdaUpdateWrapper
<
JgUseRegistration
>()
.
set
(
JgUseRegistration:
:
getSupervisionOrgCode
,
orgBranchCode
)
.
eq
(
JgUseRegistration:
:
getSequenceNbr
,
equipTransferId
)
));
}
private
void
updateSupervisionInfo
(
String
record
,
String
orgBranchName
,
String
orgBranchCode
)
{
idxBizJgSupervisionInfoService
.
update
(
new
IdxBizJgSupervisionInfo
()
.
setOrgBranchName
(
orgBranchName
)
.
setOrgBranchCode
(
orgBranchCode
),
new
QueryWrapper
<
IdxBizJgSupervisionInfo
>()
.
lambda
()
.
eq
(
IdxBizJgSupervisionInfo:
:
getRecord
,
record
)
);
}
private
void
saveResumeInfo
(
Map
<
String
,
Object
>
equ
)
{
JgResumeInfoDto
resumeInfoDto
=
JSON
.
parseObject
(
JSON
.
toJSONString
(
equ
),
JgResumeInfoDto
.
class
);
resumeInfoDto
.
setEquId
(
Objects
.
toString
(
equ
.
get
(
"resumeSeq"
),
""
));
...
...
@@ -2515,6 +2572,15 @@ public class DataDockServiceImpl {
tzsServiceFeignClient
.
commonUpdateEsDataByIds
(
objMap
);
}
public
void
updateEsOrgBranch
(
String
record
,
String
orgBranchName
,
String
orgBranchCode
)
{
HashMap
<
String
,
Map
<
String
,
Object
>>
objMap
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
param
=
new
HashMap
<>();
param
.
put
(
"ORG_BRANCH_CODE"
,
orgBranchCode
);
param
.
put
(
"ORG_BRANCH_NAME"
,
orgBranchName
);
objMap
.
put
(
record
,
param
);
tzsServiceFeignClient
.
commonUpdateEsDataByIds
(
objMap
);
}
private
void
rollBackForDelRedisData
()
{
FlowingEquipRedisContext
.
getContext
().
forEach
(
e
->
EquipUsedCheckStrategyContext
.
getUsedStrategy
(
DEFINITION_KEY
).
delDataForCheckWithKey
(
e
.
getData
(),
e
.
getRedisKey
()));
}
...
...
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/JgUseRegistrationServiceImpl.java
View file @
e0873d9f
...
...
@@ -2122,6 +2122,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
.
eq
(
JgRegistrationHistory:
:
getCurrentDocumentId
,
useRegistration
.
getSequenceNbr
())
.
set
(
JgRegistrationHistory:
:
getIsDelete
,
true
)
);
this
.
clearDataForCheckEquipRepeatUsed
(
useRegistration
);
});
}
...
...
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