Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
peizhen-java
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PeiZhen-Java
peizhen-java
Commits
0bd9710a
Commit
0bd9710a
authored
Sep 20, 2023
by
sdif
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
用户端代码提交
parent
3de7e35e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
13 deletions
+15
-13
pz-system/src/main/java/com/pz/merchant/service/impl/EmployeesServiceImpl.java
+12
-10
pz-system/src/main/resources/mapper/merchant/EmployeesMapper.xml
+3
-3
No files found.
pz-system/src/main/java/com/pz/merchant/service/impl/EmployeesServiceImpl.java
View file @
0bd9710a
...
@@ -238,19 +238,21 @@ public class EmployeesServiceImpl implements IEmployeesService {
...
@@ -238,19 +238,21 @@ public class EmployeesServiceImpl implements IEmployeesService {
@Override
@Override
public
EmployeesVo
queryByApp
(
Integer
id
)
{
public
EmployeesVo
queryByApp
(
Integer
id
)
{
EmployeesVo
employeesVo
=
baseMapper
.
selectEmployeesById
(
id
);
EmployeesVo
employeesVo
=
baseMapper
.
selectEmployeesById
(
id
);
List
<
TotalOrderVo
>
totalOrder
=
totalOrderMapper
.
selectVoList
(
Wrappers
.<
TotalOrder
>
lambdaQuery
()
if
(
null
!=
employeesVo
){
.
eq
(
TotalOrder:
:
getEmId
,
employeesVo
.
getId
())
List
<
TotalOrderVo
>
totalOrder
=
totalOrderMapper
.
selectVoList
(
Wrappers
.<
TotalOrder
>
lambdaQuery
()
.
eq
(
TotalOrder:
:
getIsSatisfaction
,
1
)
.
eq
(
TotalOrder:
:
getEmId
,
employeesVo
.
getId
())
.
orderByDesc
(
TotalOrder:
:
getId
));
.
eq
(
TotalOrder:
:
getIsSatisfaction
,
1
)
if
(
null
!=
totalOrder
&&
totalOrder
.
size
()
!=
0
){
.
orderByDesc
(
TotalOrder:
:
getId
));
for
(
TotalOrderVo
order
:
totalOrder
)
{
if
(
null
!=
totalOrder
&&
totalOrder
.
size
()
!=
0
){
BusinessVo
businessVo
=
businessMapper
.
selectVoOne
(
new
LambdaQueryWrapper
<
Business
>().
eq
(
Business:
:
getId
,
order
.
getBusinessId
()));
for
(
TotalOrderVo
order
:
totalOrder
)
{
if
(
null
!=
businessVo
)
{
BusinessVo
businessVo
=
businessMapper
.
selectVoOne
(
new
LambdaQueryWrapper
<
Business
>().
eq
(
Business:
:
getId
,
order
.
getBusinessId
()));
order
.
setProject
(
businessVo
.
getName
());
if
(
null
!=
businessVo
)
{
order
.
setProject
(
businessVo
.
getName
());
}
}
}
}
}
employeesVo
.
setTotalOrderVo
(
totalOrder
);
}
}
employeesVo
.
setTotalOrderVo
(
totalOrder
);
return
employeesVo
;
return
employeesVo
;
}
}
...
...
pz-system/src/main/resources/mapper/merchant/EmployeesMapper.xml
View file @
0bd9710a
...
@@ -102,20 +102,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
...
@@ -102,20 +102,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select
id=
"selectEmployeesById"
resultType=
"com.pz.merchant.domain.vo.EmployeesVo"
>
<select
id=
"selectEmployeesById"
resultType=
"com.pz.merchant.domain.vo.EmployeesVo"
>
SELECT e.id,
SELECT e.id,
s.avatar,
s.avatar,
e.start_year,
e.working_hours,
e.name,
e.name,
e.working_hours,
e.working_hours,
ifnull(round((sum(if(o.is_satisfaction = 1, 1, 0)) / count(o.id)) * 100, 2), 0) AS satisfaction_rate
ifnull(round((sum(if(o.is_satisfaction = 1, 1, 0)) / count(o.id)) * 100, 2), 0) AS satisfaction_rate
FROM employees e
FROM employees e
INNER
join total_order o on o.em_id = e.id
left
join total_order o on o.em_id = e.id
left join company c on c.id = e.company_id
left join company c on c.id = e.company_id
left join sys_user s on s.user_id = e.uid
left join sys_user s on s.user_id = e.uid
WHERE e.`status` = 1
WHERE e.`status` = 1
and e.now_type = 1
and e.del_flag = 0
and e.del_flag = 0
and e.id = #{id}
and e.id = #{id}
GROUP BY e.id,
GROUP BY e.id,
e.`name`
e.`name`
HAVING satisfaction_rate >= #{favorableRate};
</select>
</select>
<select
id=
"selectOrder"
resultType=
"com.pz.merchant.domain.vo.OrderInfoVO"
>
<select
id=
"selectOrder"
resultType=
"com.pz.merchant.domain.vo.OrderInfoVO"
>
...
...
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