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
b5570507
Commit
b5570507
authored
Jul 29, 2020
by
ilal
Committed by
chenzg
Jul 05, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交
parent
291320fa
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
8 deletions
+40
-8
src/main/java/cn/timer/api/controller/kqgl/TimeCardController.java
+21
-2
src/main/java/cn/timer/api/dto/kqmk/KqglMainKqzDto.java
+6
-1
src/main/resources/mapping/kqmk/KqglMainKqzMapper.xml
+13
-5
No files found.
src/main/java/cn/timer/api/controller/kqgl/TimeCardController.java
View file @
b5570507
...
...
@@ -136,7 +136,6 @@ import cn.timer.api.utils.ResponseResult;
import
cn.timer.api.utils.Result
;
import
cn.timer.api.utils.ResultUtil
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiModelProperty
;
import
io.swagger.annotations.ApiOperation
;
@Api
(
tags
=
"3.0[1]考勤模块"
)
...
...
@@ -1132,7 +1131,27 @@ public class TimeCardController {
// 缺-部门id 搜索
IPage
<
KqglMainKqzDto
>
pageAs
=
kqglmainkqzmapper
.
selectPageByQueryKqglMain
(
page
,
attquerycriteriadto
);
List
<
KqglMainKqzDto
>
listAs
=
pageAs
.
getRecords
();
return
ResultUtil
.
data
(
pageAs
,
listAs
,
"操作成功!"
);
List
<
KqglMainKqzDto
>
sumlistAs
=
new
ArrayList
<
KqglMainKqzDto
>();
for
(
KqglMainKqzDto
makq
:
listAs
)
{
KqglMainKqzDto
mas
=
KqglMainKqzDto
.
builder
().
build
();
BeanUtil
.
copyProperties
(
makq
,
mas
,
"kqzdkfslist"
);
List
<
KqglAssoKqzdkfs
>
assfs
=
KqglAssoKqzdkfs
.
builder
().
build
().
selectList
(
new
QueryWrapper
<
KqglAssoKqzdkfs
>().
lambda
().
eq
(
KqglAssoKqzdkfs:
:
getQyid
,
userBean
.
getOrgCode
())
.
eq
(
KqglAssoKqzdkfs:
:
getKqzId
,
mas
.
getId
()));
List
<
KqglAssoKqzdkfs
>
kqzdkfslist
=
new
ArrayList
<
KqglAssoKqzdkfs
>();
for
(
KqglAssoKqzdkfs
fs
:
assfs
)
{
KqglAssoKqzdkfs
dkfs
=
KqglAssoKqzdkfs
.
builder
().
build
();
dkfs
.
setKqzId
(
fs
.
getKqzId
());
dkfs
.
setType
(
fs
.
getType
());
kqzdkfslist
.
add
(
dkfs
);
}
mas
.
setKqzdkfslist
(
kqzdkfslist
);
sumlistAs
.
add
(
mas
);
}
return
ResultUtil
.
data
(
pageAs
,
sumlistAs
,
"操作成功!"
);
}
/**
...
...
src/main/java/cn/timer/api/dto/kqmk/KqglMainKqzDto.java
View file @
b5570507
package
cn
.
timer
.
api
.
dto
.
kqmk
;
import
java.util.List
;
import
cn.timer.api.bean.kqmk.KqglAssoKqzdkfs
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
...
...
@@ -87,5 +90,6 @@ public class KqglMainKqzDto {
private
String
dkfs
;
@ApiModelProperty
(
value
=
"考勤机id"
,
example
=
"3"
)
private
Integer
kqjid
;
private
List
<
KqglAssoKqzdkfs
>
kqzdkfslist
;
}
\ No newline at end of file
src/main/resources/mapping/kqmk/KqglMainKqzMapper.xml
View file @
b5570507
...
...
@@ -54,6 +54,11 @@
<result
column=
"pbfsnm"
property=
"pbfsnm"
/>
<result
column=
"dkfs"
property=
"dkfs"
/>
<result
column=
"kqjid"
property=
"kqjid"
/>
<collection
property=
"kqzdkfslist"
ofType=
"cn.timer.api.bean.kqmk.KqglAssoKqzdkfs"
>
<result
column=
"kqzId"
property=
"kqzId"
jdbcType=
"INTEGER"
/>
<result
column=
"type"
property=
"type"
jdbcType=
"INTEGER"
/>
</collection>
</resultMap>
<sql
id=
"Base_Column_List"
>
...
...
@@ -151,22 +156,25 @@
WHEN '2' then '排班制'
else '自由工时'
end as pbfsnm,
znm.kqznum,
dkfs.type
znm.kqznum
from kqgl_main_kqz kqz
LEFT JOIN (select count(yhkqz.kqzid) as kqznum,
yhkqz.kqzid as kqzid
from kqgl_asso_yhkqz yhkqz
where yhkqz.qyid = #{param.orgCode}
GROUP BY yhkqz.kqzid) as znm on znm.kqzid = kqz.id
LEFT JOIN (select kqzdkfs.kqz_id as kqzId,kqzdkfs.type as type from kqgl_asso_kqzdkfs kqzdkfs
where kqzdkfs.qyid = #{param.orgCode} ) as dkfs on dkfs.kqzId = kqz.id
where 1=1
and kqz.qyid = #{param.orgCode}
<if
test=
"param.query != null and param.query != ''"
>
and kqz.`name` like CONCAT('%',#{param.query},'%')
</if>
ORDER BY kqz.id DESC;
ORDER BY kqz.id DESC
<!-- LEFT JOIN (select kqzdkfs.kqz_id as kqzId,kqzdkfs.type as type from kqgl_asso_kqzdkfs kqzdkfs
where kqzdkfs.qyid = #{param.orgCode} ) as dkfs on dkfs.kqzId = kqz.id
dkfs.type-->
</select>
<!--
...
...
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