|
@@ -48,13 +48,13 @@
|
|
|
</select>
|
|
|
<select id="getFloorProducts" resultType="com.caimei365.commodity.model.vo.MallOrganizeProductVo">
|
|
|
SELECT
|
|
|
- cmfp.floorId,
|
|
|
+ DISTINCT cmfp.floorId,
|
|
|
p.productID AS productId,
|
|
|
- (select price from cm_sku where productID=p.productID and organizeId = 4 order by price asc limit 1) as price,
|
|
|
+ s.price as price,
|
|
|
s.normalPrice,
|
|
|
s.costPrice,
|
|
|
s.ladderPriceFlag,
|
|
|
- (select minBuyNumber from cm_sku where productID=p.productID and organizeId = 4 order by price asc limit 1) as minBuyNumber,
|
|
|
+ s.minBuyNumber as minBuyNumber,
|
|
|
IFNULL((SELECT validFlag FROM cm_organize_product_info WHERE productId = p.productID AND organizeId =4), 999) AS validFlag,
|
|
|
p.name,
|
|
|
p.mainImage
|
|
@@ -211,13 +211,13 @@
|
|
|
</select>
|
|
|
<select id="getOrganizeProducts" resultType="com.caimei365.commodity.model.vo.MallOrganizeProductVo">
|
|
|
SELECT
|
|
|
- cmfp.floorId,
|
|
|
+ DISTINCT cmfp.floorId,
|
|
|
p.productID AS productId,
|
|
|
s.normalPrice,
|
|
|
s.costPrice,
|
|
|
s.ladderPriceFlag,
|
|
|
- (SELECT price FROM cm_sku WHERE productID=p.productID and organizeId = 4 ORDER BY price ASC LIMIT 1) AS price,
|
|
|
- (select minBuyNumber from cm_sku where productID=p.productID and organizeId = 4 order by price asc limit 1) as minBuyNumber,
|
|
|
+ s.price AS price,
|
|
|
+ s.minBuyNumber as minBuyNumber,
|
|
|
IFNULL((SELECT validFlag FROM cm_organize_product_info WHERE productId = p.productID AND organizeId = 4), 999) AS validFlag,
|
|
|
p.name,
|
|
|
p.mainImage
|