@@ -56,16 +56,22 @@ public interface SubTaskMapper extends BaseMapper {
@Select("<script>"+
"select id,unid,create_time as createTime,pack_id as packId,pic_id as picId,task_id as taskId,person_unid as personUnid,status from d_sub_task where pack_id=#{packId} and person_unid in "+
"(select person_unid from d_sub_task where pack_id=#{packId}"+
" <if test = 'status != null'> and status=#{status}</if> group by person_unid "+
" <if test = 'status != null'> and status=#{status}</if> "+
" <if test = 'status == null'> and status != -1</if> "+
"group by person_unid "+
// " having count(*) > 1 " +
" order by person_unid <if test='offset != null'> offset #{offset} limit #{limit}</if>) "+
"(select person_unid from d_sub_task where pack_id=#{packId}"+
" <if test = 'status != null'> and status=#{status}</if> group by person_unid "+
" <if test = 'status != null'> and status=#{status}</if> "+
" <if test = 'status == null'> and status != -1</if> "+
" group by person_unid "+
// " having count(*) > 1 " +
") as t "+
"</script>")
...
...
@@ -73,7 +79,10 @@ public interface SubTaskMapper extends BaseMapper {
@Select("<script>"+
"select id,unid,create_time as createTime,pack_id as packId,pic_id as picId,task_id as taskId,person_unid as personUnid,status from d_sub_task where pack_id=#{packId} and person_unid="+
"(select person_unid from d_sub_task where pack_id=#{packId} <if test = 'status != null'> and status=#{status}</if> and person_unid ${type} #{personUnid} group by person_unid "+
"(select person_unid from d_sub_task where pack_id=#{packId} "+
"<if test = 'status != null'> and status=#{status}</if>"+
" <if test = 'status == null'> and status != -1</if> "+
" and person_unid ${type} #{personUnid} group by person_unid "+
// " having count(*) > 1 " +
" order by person_unid ${sort} limit 1) order by id"+