小程序主页商品接口修改
This commit is contained in:
@@ -171,7 +171,7 @@
|
|||||||
from tb_prod_sku as a
|
from tb_prod_sku as a
|
||||||
left join tb_product c on c.id=a.product_id
|
left join tb_product c on c.id=a.product_id
|
||||||
left join tb_shop_info as b on a.shop_id=b.id
|
left join tb_shop_info as b on a.shop_id=b.id
|
||||||
where c.id is not null and c.group_category_id is not null
|
where c.id is not null and c.group_category_id is not null and c.group_category_id != '[]'
|
||||||
<if test="address != null and address != ''">
|
<if test="address != null and address != ''">
|
||||||
and (b.cities like concat('%', #{address}, '%') or b.districts like concat('%', #{address}, '%'))
|
and (b.cities like concat('%', #{address}, '%') or b.districts like concat('%', #{address}, '%'))
|
||||||
</if>
|
</if>
|
||||||
@@ -180,7 +180,7 @@
|
|||||||
and c.name like concat('%', #{name}, '%')
|
and c.name like concat('%', #{name}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="classify != null">
|
<if test="classify != null">
|
||||||
and c.group_category_id = #{classify}
|
and c.group_category_id like concat('%', #{classify}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="distanceType != null">
|
<if test="distanceType != null">
|
||||||
and ST_Distance_Sphere(POINT(b.lng, b.lat), POINT(#{lng}, #{lat})) <= #{distanceType}
|
and ST_Distance_Sphere(POINT(b.lng, b.lat), POINT(#{lng}, #{lat})) <= #{distanceType}
|
||||||
@@ -213,7 +213,7 @@
|
|||||||
from tb_prod_sku as a
|
from tb_prod_sku as a
|
||||||
left join tb_product c on c.id=a.product_id
|
left join tb_product c on c.id=a.product_id
|
||||||
left join tb_shop_info as b on a.shop_id=b.id
|
left join tb_shop_info as b on a.shop_id=b.id
|
||||||
where c.group_category_id is not null and c.create_time >= date_format(now(), '%Y-%m-%d 00:00:00')
|
where c.group_category_id is not null and c.group_category_id != '[]' and c.create_time >= date_format(now(), '%Y-%m-%d 00:00:00')
|
||||||
</select>
|
</select>
|
||||||
<update id="updateProductStockNum">
|
<update id="updateProductStockNum">
|
||||||
update tb_product
|
update tb_product
|
||||||
|
|||||||
Reference in New Issue
Block a user