|
|
@@ -776,11 +776,13 @@ SELECT t.id,
|
|
|
where dn.task_id = #{taskId}
|
|
|
</select>
|
|
|
<select id="selectTaskGroup" resultType="com.xunmei.core.safetyCheck.vo.regsiter.AppPageVo">
|
|
|
+ select * from (
|
|
|
select t.plan_id as planId,
|
|
|
t.title as taskName,
|
|
|
t.plan_start_time as planStartTime,
|
|
|
t.plan_end_time as planEndTime,
|
|
|
- t.count as count
|
|
|
+ t.count as count,
|
|
|
+ sum(if(t.status!=3,1,0)) as uncompletedCount
|
|
|
from core_safety_task t
|
|
|
where t.deleted=0
|
|
|
<if test="params.beCheckedOrgId!=null">
|
|
|
@@ -815,7 +817,8 @@ SELECT t.id,
|
|
|
</foreach>))
|
|
|
</if>
|
|
|
) or t.grant_user_id=#{userId})
|
|
|
- group by t.plan_id,t.title,t.plan_start_time,t.plan_end_time,t.count
|
|
|
+ group by t.plan_id,t.title,t.plan_start_time,t.plan_end_time,t.count) tt
|
|
|
+ order by tt.uncompletedCount desc,tt.planStartTime
|
|
|
</select>
|
|
|
<select id="selectTaskList" resultType="com.xunmei.core.safetyCheck.domain.CoreSafetyTask">
|
|
|
select t.*
|