考勤统计
This commit is contained in:
@ -17,15 +17,64 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</resultMap>
|
||||
|
||||
<select id="appQueryList" resultType="com.ruoyi.bgt.domain.vo.BgtProjectRecruitApplyVO">
|
||||
select bpra.id, wu.user_id, wu.phone, wu.score, wu.avatar_name, wu.username
|
||||
select bpra.id,
|
||||
bpra.entry_time,
|
||||
wu.user_id,
|
||||
wu.phone,
|
||||
wu.score,
|
||||
wu.avatar_name,
|
||||
wu.username,
|
||||
wu.type_of_work,
|
||||
bpr.recruit_name,
|
||||
fpt.task_name
|
||||
from bgt_project_recruit_apply bpra
|
||||
left join wgz_user wu on bpra.user_id = wu.user_id
|
||||
where bpra.recruit_id = #{dto.recruitId}
|
||||
<if test="dto.status !=null and dto.status !='' ">
|
||||
and bpra.status = #{dto.status}
|
||||
left join wgz_user wu on bpra.user_id = wu.user_id
|
||||
left join bgt_project_recruit bpr on bpr.id = bpra.recruit_id
|
||||
left join fbs_project_task fpt on fpt.id = bpr.task_id
|
||||
<where>
|
||||
<if test="dto.username !=null and dto.username !='' ">
|
||||
and wu.username like concat('%', #{dto.username}, '%')
|
||||
</if>
|
||||
<if test="dto.recruitIds != null and dto.recruitIds.size() > 0">
|
||||
AND bpra.recruit_id IN
|
||||
<foreach collection="dto.recruitIds" item="recruitId" open="(" separator="," close=")">
|
||||
#{recruitId}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="dto.status != null and dto.status.size() > 0">
|
||||
AND bpra.status IN
|
||||
<foreach collection="dto.status" item="item" open="(" separator="," close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="todayAttendanceList" resultType="com.ruoyi.bgt.domain.vo.BgtProjectRecruitApplyVO">
|
||||
select bpra.id,
|
||||
bpra.entry_time,
|
||||
wu.user_id,
|
||||
wu.phone,
|
||||
wu.score,
|
||||
wu.avatar_name,
|
||||
wu.username,
|
||||
wu.type_of_work,
|
||||
bpr.recruit_name,
|
||||
fpt.task_name
|
||||
from wgz_attendance wa
|
||||
left join wgz_user wu on wa.user_id = wu.user_id
|
||||
left join bgt_project_recruit_apply bpra on wa.recruit_id = bpra.recruit_id and bpra.user_id = wa.user_id
|
||||
left join bgt_project_recruit bpr on bpr.id = bpra.recruit_id
|
||||
left join fbs_project_task fpt on fpt.id = bpr.task_id
|
||||
where wa.date = #{dto.date}'
|
||||
<if test="dto.attendanceType !=null and dto.attendanceType ==1 ">
|
||||
and (wa.missed_in =0 or missed_out = 0 )
|
||||
</if>
|
||||
<if test="dto.username !=null and dto.username !='' ">
|
||||
and wu.username like concat('%', #{dto.username}, '%')
|
||||
<if test="dto.attendanceType !=null and dto.attendanceType ==2 ">
|
||||
and (wa.missed_in =1 and missed_out = 1 )
|
||||
</if>
|
||||
<if test="dto.attendanceType !=null and dto.attendanceType ==3 ">
|
||||
and wa.late =1
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
Reference in New Issue
Block a user