|
|
@@ -23,7 +23,7 @@ public interface YhShopGoodsSkuMapper extends BaseMapper<YhShopGoodsSku> {
|
|
|
@Update("update yh_shop_goods_sku set status = 0 where sku_id = #{skuId} and price not between #{minPrice} and #{maxPrice}")
|
|
|
Integer setBelowPriceShopSkuDown(@Param("skuId") Long skuId, @Param("minPrice") BigDecimal minPrice, @Param("maxPrice") BigDecimal maxPrice);
|
|
|
|
|
|
- @Select("select sku_id,price from yh_shop_goods_sku where yhs_id = #{yhsId} and goods_id = #{goodsId} and deleted is true and status is true order by price limit 1")
|
|
|
+ @Select("select sku_id,price from yh_shop_goods_sku ys where yhs_id = #{yhsId} and goods_id = #{goodsId} and deleted is true and status is true and exists(select 1 from goods_don_sku sku where sku.id = ys.sku_id and sku.status is true) order by price limit 1")
|
|
|
YhShopGoodsSku selectMinPriceSkuByYhsId(@Param("yhsId") Long yhsId, @Param("goodsId") Long goodsId);
|
|
|
|
|
|
@Select("select * from yh_shop_goods_sku where sku_id = #{skuId} and price not between #{minPrice} and #{maxPrice} and status = 1")
|