Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
8
8timerapiv200
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
8timerv2
8timerapiv200
Commits
acb3d478
Commit
acb3d478
authored
Mar 26, 2020
by
太阳与水
Committed by
chenzg
Jul 05, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更改员工搜索为实川的员工搜索接口
parent
149ce4be
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
6 deletions
+15
-6
src/main/java/cn/timer/api/controller/yggl/YgglController.java
+15
-6
No files found.
src/main/java/cn/timer/api/controller/yggl/YgglController.java
View file @
acb3d478
...
...
@@ -271,25 +271,34 @@ public class YgglController {
@ApiOperation
(
value
=
"员工搜索/分页"
,
httpMethod
=
"POST"
,
notes
=
"接口发布说明"
)
@ApiOperationSupport
(
order
=
52
)
public
Result
<
Object
>
ygquery
(
@CurrentUser
UserBean
userBean
,
@RequestBody
YgQueryDto
ygQueryDto
)
{
Integer
orgCode
=
userBean
.
getOrgCode
();
Integer
b
=
ygQueryDto
.
getBmgwid
();
ArrayList
<
Integer
>
bList
=
new
ArrayList
<
Integer
>();
List
<
ZzglBmgwM
>
zzglBmgwMs
=
new
LambdaQueryChainWrapper
<
ZzglBmgwM
>(
zzglBmgwMMapper
)
.
eq
(
ZzglBmgwM:
:
getOrgCode
,
orgCode
).
list
();
ZzglBmgwM
.
getDepts
(
bList
,
b
,
zzglBmgwMs
);
Integer
j
=
ygQueryDto
.
getJobStatus
();
Integer
t
=
ygQueryDto
.
getJobType
();
String
q
=
ygQueryDto
.
getQuery
();
Page
<
YgglMainEmp
>
page
=
new
Page
<
YgglMainEmp
>(
ygQueryDto
.
getCurrentPage
()
==
null
?
1
:
ygQueryDto
.
getCurrentPage
(),
ygQueryDto
.
getTotalPage
()
==
null
?
10
:
ygQueryDto
.
getTotalPage
());
QueryWrapper
<
YgglMainEmp
>
queryWrapper
=
new
QueryWrapper
<>();
queryWrapper
.
eq
(
"org_code"
,
userBean
.
getOrgCode
()).
eq
(
t
!=
null
&&
t
>
-
1
,
"job_type"
,
t
)
.
eq
(
b
!=
null
&&
b
>
-
1
,
"bmgw_id"
,
b
).
eq
(
j
!=
null
&&
j
>
-
1
,
"job_status"
,
j
)
.
and
(!
StrUtil
.
hasBlank
(
q
),
wq
->
wq
.
likeRight
(
"name"
,
q
).
or
().
likeRight
(
"phone"
,
q
));
queryWrapper
.
select
(
"name"
,
"emp_num"
,
"bmgw_id"
,
"rz_time"
,
"job_type"
,
"phone"
,
"job_status"
)
.
eq
(
"org_code"
,
orgCode
).
eq
(
t
!=
null
&&
t
>
-
1
,
"job_type"
,
t
)
.
eq
(
j
!=
null
&&
j
>
-
1
,
"job_status"
,
j
).
in
(!
bList
.
isEmpty
(),
"id"
,
bList
)
.
and
(!
StrUtil
.
hasBlank
(
q
),
wq
->
wq
.
like
(
"name"
,
q
).
or
().
like
(
"phone"
,
q
));
// List<YgglMainEmp> lo = YgglMainEmp.builder().build().selectList(queryWrapper);
IPage
<
YgglMainEmp
>
ygglMainEmpPage
=
YgglMainEmp
.
builder
().
build
().
selectPage
(
page
,
queryWrapper
);
List
<
YgglMainEmp
>
ygglMainEmps
=
ygglMainEmpPage
.
getRecords
();
//
List<YgglMainEmp> ygglMainEmps = ygglMainEmpPage.getRecords();
ygglMainEmpPage
.
getCurrent
();
ygglMainEmpPage
.
getPages
();
ygglMainEmpPage
.
getTotal
();
ygglMainEmpPage
.
getSize
();
return
ResultUtil
.
data
(
ygglMainEmpPage
,
ygglMainEmps
,
"员工搜索成功"
);
return
ResultUtil
.
data
(
ygglMainEmpPage
,
"员工搜索成功"
);
// return ResultUtil.data(ygglMainEmpPage, ygglMainEmps, "员工搜索成功");
}
...
...
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