|
@@ -54,15 +54,21 @@
|
|
|
left join os_task tas2 on tas.task_condition_id = tas2.task_condition_id and tas.ctime < tas2.ctime
|
|
|
left join task_condition con on tas.task_condition_id = con.id
|
|
|
<where>
|
|
|
- <if test="projectId != null">
|
|
|
+ <if test="projectId != null and projectId != 0">
|
|
|
and tas.tid = #{projectId}
|
|
|
</if>
|
|
|
- <if test="reportId != null">
|
|
|
+ <if test="reportId != null and reportId != 0">
|
|
|
and tas.report_id = #{reportId}
|
|
|
</if>
|
|
|
<if test="projectId == null and reportId == null">
|
|
|
and tas.uid = #{createId}
|
|
|
</if>
|
|
|
+ <if test="projectId == 0 and reportId == null">
|
|
|
+ and tas.tid != 0
|
|
|
+ </if>
|
|
|
+ <if test="reportId == 0 and projectId == null">
|
|
|
+ and tas.report_id is not null
|
|
|
+ </if>
|
|
|
<if test="personIds != null and personIds.size > 0">
|
|
|
and tas.uid in
|
|
|
<foreach collection="personIds" item="n" separator="," open="(" close=")">
|