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
3b3ec5de
Commit
3b3ec5de
authored
Jun 18, 2020
by
邓实川
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
员工查询列表优化
parent
a620710b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
src/main/java/cn/timer/api/controller/dzht/DzhtController2.java
+6
-7
src/main/resources/mapping/yggl/YgglMainEmpMapper.xml
+1
-0
No files found.
src/main/java/cn/timer/api/controller/dzht/DzhtController2.java
View file @
3b3ec5de
...
...
@@ -42,7 +42,6 @@ import cn.timer.api.bean.dzht.DzhtAssoQyyz;
import
cn.timer.api.bean.dzht.DzhtAssoQyzc
;
import
cn.timer.api.bean.dzht.DzhtAssoSdgzq
;
import
cn.timer.api.bean.dzht.DzhtAssoTpyz
;
import
cn.timer.api.bean.qyzx.QyzxEmpEntAsso
;
import
cn.timer.api.bean.qyzx.businessService.QyzxRemainingQuantity
;
import
cn.timer.api.bean.qyzx.businessService.QyzxUseRecord
;
import
cn.timer.api.bean.yggl.YgglMainEmp
;
...
...
@@ -206,16 +205,16 @@ public class DzhtController2 {
@GetMapping
(
"/getOrganizations"
)
@ApiOperation
(
value
=
"查询企业信息s"
,
httpMethod
=
"GET"
,
notes
=
"接口发布说明"
)
public
Result
<
Object
>
getOrganizations
(
@CurrentUser
UserBean
userBean
)
{
List
<
QyzxEmpEntAsso
>
list
=
QyzxEmpEntAsso
.
builder
().
build
().
selectList
(
new
QueryWrapper
<
QyzxEmpEntAsso
>().
lambda
().
eq
(
QyzxEmpEntAsso:
:
getEmpNum
,
userBean
.
getEmpNum
()));
List
<
Integer
>
orgCodeList
=
Lists
.
transform
(
list
,
newList
->
newList
.
getOrgCode
());
//
List<QyzxEmpEntAsso> list = QyzxEmpEntAsso.builder().build().selectList(
//
new QueryWrapper<QyzxEmpEntAsso>().lambda().eq(QyzxEmpEntAsso::getEmpNum, userBean.getEmpNum()));
//
List<Integer> orgCodeList = Lists.transform(list, newList -> newList.getOrgCode());
List
<
String
>
orgIds
=
new
ArrayList
<
String
>();
for
(
Integer
orgCode
:
orgCodeList
)
{
//
for (Integer orgCode : orgCodeList) {
DzhtAssoQyzc
qyzc
=
DzhtAssoQyzc
.
builder
().
build
().
selectOne
(
new
QueryWrapper
<
DzhtAssoQyzc
>().
lambda
()
.
eq
(
DzhtAssoQyzc:
:
getOrgCode
,
orgCode
).
select
(
DzhtAssoQyzc:
:
getOrgId
));
.
eq
(
DzhtAssoQyzc:
:
getOrgCode
,
userBean
.
getOrgCode
()
).
select
(
DzhtAssoQyzc:
:
getOrgId
));
if
(
qyzc
!=
null
)
orgIds
.
add
(
qyzc
.
getOrgId
());
}
//
}
JSONObject
j
=
null
;
List
<
JSONObject
>
result
=
new
ArrayList
<
JSONObject
>();
try
{
...
...
src/main/resources/mapping/yggl/YgglMainEmpMapper.xml
View file @
3b3ec5de
...
...
@@ -211,6 +211,7 @@
FROM yggl_main_emp a
<where>
AND a.org_code = #{param.orgCode}
AND a.job_status != 3
<if
test=
"param.jobType != null"
>
AND a.job_type = #{param.jobType}
</if>
...
...
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