视频圈
This commit is contained in:
parent
a15128c7b5
commit
23178562b2
|
@ -37,24 +37,21 @@
|
|||
if(c.id is null,0,1) as sfdz
|
||||
FROM bl_shipinquan a
|
||||
left join artificer b on a.create_by = b.user_id
|
||||
left join bl_shipinquan_dianzan c on a.id = c.shipinquan_id <if test="params.userId!=null and params.userId!=''">and c.create_by = #{params.userId}</if>
|
||||
left join bl_shipinquan_dianzan c on a.id = c.shipinquan_id
|
||||
<if test="params.userId!=null and params.userId!=''">and c.create_by = #{params.userId}</if>
|
||||
left join collect_artificer d on b.artificer_id = d.artificer_id
|
||||
<if test="params.userId!=null and params.userId!=''">and d.user_id = #{params.userId}</if>
|
||||
<where>
|
||||
<if test="params.userId!=null and params.userId!=''">
|
||||
and d.user_id = #{params.userId}
|
||||
</if>
|
||||
<if test="params.createBy!=null and params.createBy!=''">
|
||||
and a.create_by = #{params.createBy}
|
||||
</if>
|
||||
</where>
|
||||
|
||||
<if test="params.longitude!=null and params.longitude!='' and params.latitude!=null and params.latitude!=''">
|
||||
order by (st_distance (point (b.longitude, b.latitude),point(#{params.longitude},#{params.longitude}) ) *111195) asc,create_time desc
|
||||
</if>
|
||||
<if test="params.longitude==null or params.longitude=='' or params.latitude==null or params.latitude==''">
|
||||
order by create_time desc
|
||||
</if>
|
||||
|
||||
</select>
|
||||
|
||||
</mapper>
|
Loading…
Reference in New Issue