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
2187bfff
Commit
2187bfff
authored
Jan 09, 2025
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.管道历史问题处理
parent
d40ef5af
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
86 additions
and
0 deletions
+86
-0
PieLineEquipContraptionDto.java
...os/boot/module/jg/api/dto/PieLineEquipContraptionDto.java
+22
-0
JgInstallationNoticeEqMapper.java
...ot/module/jg/api/mapper/JgInstallationNoticeEqMapper.java
+9
-0
JgInstallationNoticeEqMapper.xml
...rc/main/resources/mapper/JgInstallationNoticeEqMapper.xml
+20
-0
DataHandlerController.java
.../boot/module/jg/biz/controller/DataHandlerController.java
+8
-0
DataHandlerServiceImpl.java
...ot/module/jg/biz/service/impl/DataHandlerServiceImpl.java
+27
-0
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/dto/PieLineEquipContraptionDto.java
0 → 100644
View file @
2187bfff
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
dto
;
import
lombok.Data
;
@Data
public
class
PieLineEquipContraptionDto
{
/**
* 装置id
*/
private
String
projectContraptionId
;
/**
* 装置名称
*/
private
String
projectContraption
;
/**
* 设备record
*/
private
String
record
;
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/mapper/JgInstallationNoticeEqMapper.java
View file @
2187bfff
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.jg.api.dto.PieLineEquipContraptionDto
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgInstallationNoticeEq
;
import
java.util.List
;
...
...
@@ -28,4 +29,12 @@ public interface JgInstallationNoticeEqMapper extends CustomBaseMapper<JgInstall
*/
List
<
JgInstallationNoticeEq
>
selectPCIdNeErrorPieLineInUseInfo
();
/**
* 查询安装告知(非删除、已作废)的装置id和设备的使用信息装置id不一样的设备
*
* @return List<JgInstallationNoticeEq> 管道record数组
*/
List
<
PieLineEquipContraptionDto
>
selectPCIdNeErrorPieLineInUseInfo2
();
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgInstallationNoticeEqMapper.xml
View file @
2187bfff
...
...
@@ -34,4 +34,24 @@
and u.project_contraption_id != n.project_contraption_id
and pc."rec_user_name" LIKE '%杨生元%' AND pc."rec_date" >= '2025-01-06 00:00:00'
</select>
<select
id=
"selectPCIdNeErrorPieLineInUseInfo2"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.PieLineEquipContraptionDto"
>
SELECT
ne.equ_id as record,
pc.project_contraption,
pc.sequence_nbr as project_contraption_id
FROM
"tzs_jg_installation_notice" n,
tzs_jg_installation_notice_eq ne,
"idx_biz_jg_use_info" u,
idx_biz_jg_project_contraption pc
WHERE
ne.equip_transfer_id = n.sequence_nbr
and ne.equ_id = u."RECORD"
and pc.sequence_nbr = n.project_contraption_id
and n.is_delete = '0'
and n.notice_status != '6617'
and u.project_contraption_id != n.project_contraption_id
and pc.usc_unit_credit_code = n.install_unit_credit_code
order by n.create_date
</select>
</mapper>
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/DataHandlerController.java
View file @
2187bfff
...
...
@@ -111,5 +111,13 @@ public class DataHandlerController extends BaseController {
return
ResponseHelper
.
buildResponse
(
true
);
}
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"20250109-之前刷库问题导致的管道的装置id与安装告知不一样,已安装告知为准,刷使用信息表的装置id、es的装置id【只处理未做过使用登记或者使用登记未完成的】"
,
notes
=
"历史数据处理"
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/v4/projectContraption/useInfo"
)
public
ResponseModel
<
Boolean
>
projectUseInfoUpdateV4
(){
dataHandlerService
.
projectUseInfoUpdateV4
();
return
ResponseHelper
.
buildResponse
(
true
);
}
}
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/DataHandlerServiceImpl.java
View file @
2187bfff
...
...
@@ -15,6 +15,7 @@ import com.yeejoin.amos.boot.biz.common.entity.DataDictionary;
import
com.yeejoin.amos.boot.biz.common.utils.SnowflakeIdUtil
;
import
com.yeejoin.amos.boot.module.common.api.dao.ESEquipmentCategory
;
import
com.yeejoin.amos.boot.module.common.api.dto.ESEquipmentCategoryDto
;
import
com.yeejoin.amos.boot.module.jg.api.dto.PieLineEquipContraptionDto
;
import
com.yeejoin.amos.boot.module.jg.api.entity.*
;
import
com.yeejoin.amos.boot.module.jg.api.enums.PipelineEnum
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.JgInstallationNoticeEqMapper
;
...
...
@@ -902,4 +903,30 @@ public class DataHandlerServiceImpl {
private
List
<
JgInstallationNotice
>
getNotInsertProjectConstructionInstallNotice
()
{
return
jgInstallationNoticeMapper
.
selectNotInsertProjectConstructionInstallNoticeList
();
}
/**
* 之前刷库问题导致的管道的装置id与安装告知的装置id的不一样的数据刷库
* 已安装告知为准,刷1.使用信息表的装置id;2.es的装置id。进行比对装置的安装信息与安装告知的信息安装信息对上才刷【使用登记审批完成后,装置表的安装单位信息回清空,故不包括这部分数据】】
*/
public
void
projectUseInfoUpdateV4
()
{
List
<
PieLineEquipContraptionDto
>
eqs
=
jgInstallationNoticeEqMapper
.
selectPCIdNeErrorPieLineInUseInfo2
();
log
.
info
(
"处理前:查询管道的装置id与安装告知的装置id的不一样管道设备:{}"
,
eqs
.
size
());
eqs
.
forEach
(
eq
->{
Optional
<
ESEquipmentCategoryDto
>
equInfosWithEs
=
esEquipmentCategory
.
findById
(
eq
.
getRecord
());
equInfosWithEs
.
ifPresent
(
equInfoEs
->
{
// 已安装告知单据为准更新es
equInfoEs
.
setProjectContraptionId
(
eq
.
getProjectContraptionId
());
equInfoEs
.
setPROJECT_CONTRAPTION
(
eq
.
getProjectContraption
());
esEquipmentCategory
.
save
(
equInfoEs
);
// 已安装告知单据为准更新use_info
LambdaUpdateWrapper
<
IdxBizJgUseInfo
>
updateWrapper
=
new
LambdaUpdateWrapper
<>();
updateWrapper
.
eq
(
IdxBizJgUseInfo:
:
getRecord
,
eq
.
getRecord
());
updateWrapper
.
set
(
IdxBizJgUseInfo:
:
getProjectContraptionId
,
eq
.
getProjectContraptionId
());
updateWrapper
.
set
(
IdxBizJgUseInfo:
:
getProjectContraption
,
eq
.
getProjectContraption
());
useInfoService
.
update
(
updateWrapper
);
});
});
List
<
PieLineEquipContraptionDto
>
eqsAfter
=
jgInstallationNoticeEqMapper
.
selectPCIdNeErrorPieLineInUseInfo2
();
log
.
info
(
"处理后:查询管道装置id与安装告知的装置id的不一样管道设备:{}"
,
eqsAfter
.
size
());
}
}
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