|
|
@@ -601,8 +601,14 @@ a.annex_url annexUrl ,a.remarks,a.duration ,a.valid_date validDate ,a.latitude ,
|
|
|
from public_release a left join `user` b on a.uid=b.id left join admin c on a.aid =c.id
|
|
|
left join admin d on b.aid=d.id where 1=1
|
|
|
<if test="aid != null">
|
|
|
- and a.aid= #{aid}
|
|
|
- </if>
|
|
|
+ and a.aid= #{aid}
|
|
|
+ </if>
|
|
|
+ <if test="sid != null">
|
|
|
+ and d.aid= #{sid}
|
|
|
+ </if>
|
|
|
+ <if test="depId != null">
|
|
|
+ and d.department_id = #{depId}
|
|
|
+ </if>
|
|
|
<if test="type==1 and deps !=null">
|
|
|
and d.department_id in
|
|
|
<foreach close=")" collection="deps" item="deps" open="(" separator=",">
|
|
|
@@ -621,6 +627,7 @@ a.annex_url annexUrl ,a.remarks,a.duration ,a.valid_date validDate ,a.latitude ,
|
|
|
<if test="clockIn !=null">
|
|
|
and a.clock_in= #{clockIn}
|
|
|
</if>
|
|
|
+ order by a.status,a.create_time desc
|
|
|
<if test="page_sql!=null">
|
|
|
${page_sql}
|
|
|
</if>
|
|
|
@@ -631,27 +638,33 @@ a.annex_url annexUrl ,a.remarks,a.duration ,a.valid_date validDate ,a.latitude ,
|
|
|
from public_release a left join `user` b on a.uid=b.id left join admin c on a.aid =c.id
|
|
|
left join admin d on b.aid=d.id
|
|
|
where 1=1
|
|
|
- <if test="aid != null">
|
|
|
- and a.aid= #{aid}
|
|
|
- </if>
|
|
|
+ <if test="aid != null">
|
|
|
+ and a.aid= #{aid}
|
|
|
+ </if>
|
|
|
+ <if test="sid != null">
|
|
|
+ and d.aid= #{sid}
|
|
|
+ </if>
|
|
|
+ <if test="depId != null">
|
|
|
+ and d.department_id = #{depId}
|
|
|
+ </if>
|
|
|
<if test="type==1 and deps !=null">
|
|
|
and d.department_id in
|
|
|
<foreach close=")" collection="deps" item="deps" open="(" separator=",">
|
|
|
#{deps.id}
|
|
|
</foreach>
|
|
|
</if>
|
|
|
- <if test="uid != null">
|
|
|
- and a.uid = #{uid}
|
|
|
- </if>
|
|
|
- <if test="releaseStart != null and releaseEnd != null">
|
|
|
- and (a.release_start between #{releaseStart} and #{releaseEnd} or a.release_end between #{releaseStart} and #{releaseEnd})
|
|
|
- </if>
|
|
|
- <if test="status != null">
|
|
|
- and a.status = #{status}
|
|
|
- </if>
|
|
|
- <if test="clockIn !=null">
|
|
|
- and a.clock_in= #{clockIn}
|
|
|
- </if>
|
|
|
+ <if test="uid != null">
|
|
|
+ and a.uid = #{uid}
|
|
|
+ </if>
|
|
|
+ <if test="releaseStart != null and releaseEnd != null">
|
|
|
+ and (a.release_start between #{releaseStart} and #{releaseEnd} or a.release_end between #{releaseStart} and #{releaseEnd})
|
|
|
+ </if>
|
|
|
+ <if test="status != null">
|
|
|
+ and a.status = #{status}
|
|
|
+ </if>
|
|
|
+ <if test="clockIn !=null">
|
|
|
+ and a.clock_in= #{clockIn}
|
|
|
+ </if>
|
|
|
</select>
|
|
|
|
|
|
<select id="checkTime" resultType="java.lang.Integer">
|