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
98c8c710
Commit
98c8c710
authored
Nov 13, 2024
by
刘林
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(statistics):设备履历信息去重
parent
16be5c57
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
62 additions
and
29 deletions
+62
-29
CommonMapper.xml
...-module-jg-api/src/main/resources/mapper/CommonMapper.xml
+19
-12
JgResumeInfoServiceImpl.java
...t/module/jg/biz/service/impl/JgResumeInfoServiceImpl.java
+15
-5
JgUseRegistrationServiceImpl.java
...ule/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
+9
-0
DPSubBizMapper.xml
...atistics-api/src/main/resources/mapper/DPSubBizMapper.xml
+19
-12
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/CommonMapper.xml
View file @
98c8c710
...
...
@@ -114,19 +114,26 @@
</select>
<select
id=
"equOnJgServiceOperationRecords"
resultType=
"java.util.Map"
>
select
sequence_nbr as
sequenceNbr,
business_type as
businessType,
apply_no as
applyNo,
rec_User_Id as
recUserId,
rec_user_name as
recUserName,
SELECT
t.sequence_nbr AS
sequenceNbr,
t.business_type AS
businessType,
t.apply_no AS
applyNo,
t.rec_user_id AS
recUserId,
t.rec_user_name AS
recUserName,
DATE_FORMAT(rec_date,'%Y-%m-%d %H:%i:%s') as recDate,
approval_unit as approvalUnit,
status,
route_path as routePath
from tzs_jg_resume_info
where equ_id = #{record}
order by rec_date ASC
t.approval_unit AS approvalUnit,
t.status,
t.route_path AS routePath
FROM
tzs_jg_resume_info t
JOIN (SELECT apply_no, MAX(rec_date) AS max_rec_date
FROM tzs_jg_resume_info
WHERE equ_id = #{record}
GROUP BY apply_no
) AS latest
ON t.apply_no = latest.apply_no AND t.rec_date = latest.max_rec_date
WHERE t.equ_id = #{record}
ORDER BY t.rec_date ASC
</select>
<select
id=
"selectPromoterData"
resultType=
"java.lang.String"
>
select
...
...
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/JgResumeInfoServiceImpl.java
View file @
98c8c710
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
biz
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgResumeInfoDto
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgResumeInfo
;
...
...
@@ -19,19 +20,19 @@ import java.util.stream.Collectors;
* @date 2024-05-29
*/
@Service
public
class
JgResumeInfoServiceImpl
extends
BaseService
<
JgResumeInfoDto
,
JgResumeInfo
,
JgResumeInfoMapper
>
implements
IJgResumeInfoService
{
public
class
JgResumeInfoServiceImpl
extends
BaseService
<
JgResumeInfoDto
,
JgResumeInfo
,
JgResumeInfoMapper
>
implements
IJgResumeInfoService
{
/**
* 分页查询
*/
public
Page
<
JgResumeInfoDto
>
queryForJgResumeInfoPage
(
Page
<
JgResumeInfoDto
>
page
)
{
public
Page
<
JgResumeInfoDto
>
queryForJgResumeInfoPage
(
Page
<
JgResumeInfoDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
}
/**
* 列表查询 示例
*/
public
List
<
JgResumeInfoDto
>
queryForJgResumeInfoList
()
{
return
this
.
queryForList
(
""
,
false
);
public
List
<
JgResumeInfoDto
>
queryForJgResumeInfoList
()
{
return
this
.
queryForList
(
""
,
false
);
}
public
void
saveBatchResume
(
List
<
JgResumeInfoDto
>
jgResumeInfoDtoList
)
{
...
...
@@ -42,6 +43,14 @@ public class JgResumeInfoServiceImpl extends BaseService<JgResumeInfoDto,JgResum
return
info
;
})
.
collect
(
Collectors
.
toList
());
this
.
saveBatch
(
jgResumeInfoCollection
);
this
.
saveBatch
(
jgResumeInfoCollection
);
}
/**
* 根据业务id进行删除
* @param businessId 业务id
*/
public
void
deleteByBusinessId
(
String
businessId
)
{
this
.
baseMapper
.
delete
(
new
LambdaQueryWrapper
<
JgResumeInfo
>().
eq
(
JgResumeInfo:
:
getBusinessId
,
businessId
));
}
}
\ No newline at end of file
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 @
98c8c710
...
...
@@ -3115,6 +3115,15 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
// 历史设备 生成证书管理表记录 & 生成安装 维保等操作记录
this
.
historyEquGenManageRelated
(
map
,
jgUseRegistration
,
registerInfo
,
idxBizJgFactoryInfo
);
jgResumeInfoService
.
createWithModel
(
JgResumeInfoDto
.
builder
()
.
applyNo
(
jgUseRegistration
.
getApplyNo
())
.
businessType
(
BusinessTypeEnum
.
JG_HISTORY_USAGE_REGISTRATION
.
getName
())
.
businessId
(
jgUseRegistration
.
getSequenceNbr
()
+
""
)
.
equId
(
String
.
valueOf
(
map
.
get
(
"equipId"
)))
.
approvalUnit
(
jgUseRegistration
.
getReceiveOrgName
())
.
approvalUnitCode
(
jgUseRegistration
.
getReceiveOrgCode
())
.
status
(
"正常"
)
.
build
());
}
return
this
.
baseMapper
.
getDetailById
(
jgUseRegistration
.
getSequenceNbr
());
}
catch
(
BadRequest
|
LocalBadRequest
e
)
{
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-api/src/main/resources/mapper/DPSubBizMapper.xml
View file @
98c8c710
...
...
@@ -3,19 +3,26 @@
<mapper
namespace=
"com.yeejoin.amos.boot.module.statistics.api.mapper.DPSubBizMapper"
>
<select
id=
"equOnJgServiceOperationRecords"
resultType=
"java.util.Map"
>
select
sequence_nbr as
sequenceNbr,
business_type as
businessType,
apply_no as
applyNo,
rec_User_Id as
recUserId,
rec_user_name as
recUserName,
SELECT
t.sequence_nbr AS
sequenceNbr,
t.business_type AS
businessType,
t.apply_no AS
applyNo,
t.rec_user_id AS
recUserId,
t.rec_user_name AS
recUserName,
DATE_FORMAT(rec_date,'%Y-%m-%d %H:%i:%s') as recDate,
approval_unit as approvalUnit,
status,
route_path as routePath
from tzs_jg_resume_info
where equ_id = #{record}
order by rec_date ASC
t.approval_unit AS approvalUnit,
t.status,
t.route_path AS routePath
FROM
tzs_jg_resume_info t
JOIN (SELECT apply_no, MAX(rec_date) AS max_rec_date
FROM tzs_jg_resume_info
WHERE equ_id = #{record}
GROUP BY apply_no
) AS latest
ON t.apply_no = latest.apply_no AND t.rec_date = latest.max_rec_date
WHERE t.equ_id = #{record}
ORDER BY t.rec_date ASC
</select>
<select
id=
"queryForSafetyProblemTracingList"
resultType=
"java.util.Map"
>
...
...
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