|
@@ -38,8 +38,8 @@
|
|
|
</foreach>
|
|
|
)
|
|
|
</if>
|
|
|
- <if test="userId !=null and companyId !=null and cooperateSceneCodes !=null and cooperateSceneCodes.size ==0 ">
|
|
|
- and (co.id = #{companyId} or s.user_id = #{userId} )
|
|
|
+ <if test="param.userId !=null and param.companyId !=null and param.cooperateSceneCodes !=null and param.cooperateSceneCodes.size ==0 ">
|
|
|
+ and (co.id = #{param.companyId} or s.user_id = #{param.userId} )
|
|
|
</if>
|
|
|
|
|
|
UNION
|
|
@@ -50,24 +50,24 @@
|
|
|
LEFT JOIN t_user u on s.user_id = u.id
|
|
|
LEFT JOIN t_company co on u.company_id = co.id
|
|
|
WHERE s.rec_status = 'A' and s.scene_status = -2 and gps.num is not null
|
|
|
- <if test="searchKey != null and searchKey!='' ">
|
|
|
- and (s.title like concat ('%',#{searchKey},'%') or s.laser_title like concat ('%',#{searchKey},'%') )
|
|
|
+ <if test="param.searchKey != null and param.searchKey!='' ">
|
|
|
+ and (s.title like concat ('%',#{param.searchKey},'%') or s.laser_title like concat ('%',#{param.searchKey},'%') )
|
|
|
</if>
|
|
|
- <if test="numList !=null and numList.size >0">
|
|
|
+ <if test="param.numList !=null and param.numList.size >0">
|
|
|
and s.num in
|
|
|
<foreach collection="numList" item="num" open="(" separator="," close=")">
|
|
|
#{num}
|
|
|
</foreach>
|
|
|
</if>
|
|
|
- <if test="userId !=null and companyId !=null and cooperateSceneCodes !=null and cooperateSceneCodes.size >0">
|
|
|
- and ( s.user_id = #{userId} or co.id = #{companyId} or s.num in
|
|
|
- <foreach collection="cooperateSceneCodes" item="coNum" open="(" separator="," close=")">
|
|
|
+ <if test="param.userId !=null and param.companyId !=null and param.cooperateSceneCodes !=null and param.cooperateSceneCodes.size >0">
|
|
|
+ and ( s.user_id = #{param.userId} or co.id = #{param.companyId} or s.num in
|
|
|
+ <foreach collection="param.cooperateSceneCodes" item="coNum" open="(" separator="," close=")">
|
|
|
#{coNum}
|
|
|
</foreach>
|
|
|
)
|
|
|
</if>
|
|
|
- <if test="userId !=null and companyId !=null and cooperateSceneCodes !=null and cooperateSceneCodes.size ==0 ">
|
|
|
- and (co.id = #{companyId} or s.user_id = #{userId} )
|
|
|
+ <if test="param.userId !=null and param.companyId !=null and param.cooperateSceneCodes !=null and param.cooperateSceneCodes.size ==0 ">
|
|
|
+ and (co.id = #{param.companyId} or s.user_id = #{param.userId} )
|
|
|
</if>
|
|
|
|
|
|
</select>
|