分包
This commit is contained in:
@ -54,4 +54,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="getProgressByTaskIds" resultType="com.ruoyi.bgt.domain.BgtProjectTaskProgress">
|
||||
SELECT t.*
|
||||
FROM bgt_project_task_progress t
|
||||
JOIN (
|
||||
SELECT task_id, MAX(progress) AS maxProgress
|
||||
FROM bgt_project_task_progress
|
||||
WHERE audit_status = '2' and task_id IN
|
||||
<foreach item="taskId" collection="taskIds" open="(" separator="," close=")">
|
||||
#{taskId}
|
||||
</foreach>
|
||||
GROUP BY task_id
|
||||
) sub ON t.task_id = sub.task_id AND t.progress = sub.maxProgress
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
@ -27,7 +27,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
bu.avatar_name
|
||||
from fbs_project_task_apply fpta
|
||||
left join bgt_user bu on fpta.user_id = bu.user_id
|
||||
where fpta.task_id = #{dto.taskId}
|
||||
where fpta.task_id = #{dto.taskId} and fpta.apply_status != '3'
|
||||
<if test="dto.applyStatus != null and dto.applyStatus != ''">
|
||||
and fpta.apply_status = #{dto.applyStatus}
|
||||
</if>
|
||||
|
@ -66,6 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
FROM fbs_project_task_apply
|
||||
WHERE task_id = fpt.id
|
||||
AND user_id = #{dto.userId}
|
||||
AND apply_status in ('0','1','2')
|
||||
)
|
||||
</if>
|
||||
<if test='dto.myTask and dto.status != null and dto.status == "0"'>
|
||||
@ -74,6 +75,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
FROM fbs_project_task_apply
|
||||
WHERE task_id = fpt.id
|
||||
AND user_id = #{dto.userId}
|
||||
AND apply_status in ('0','1')
|
||||
)
|
||||
</if>
|
||||
<if test="dto.taskName != null and dto.taskName != '' ">
|
||||
|
@ -91,7 +91,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
project_img,
|
||||
project_status
|
||||
FROM zbf_project zp
|
||||
zp.id in (select zpsa.project_id from zbf_project_subcontracting_apply zpsa where zpsa.fbs_user_id = #{dto.fbsUserId})
|
||||
where zp.id in (select zpsa.project_id from zbf_project_subcontracting_apply zpsa where zpsa.fbs_user_id = #{dto.fbsUserId})
|
||||
order by zp.id desc
|
||||
</select>
|
||||
|
||||
|
Reference in New Issue
Block a user