|
|
@@ -13,8 +13,10 @@ import java.util.List;
|
|
|
* @date 2023/9/15 09:42
|
|
|
*/
|
|
|
@Data
|
|
|
-@SearchBean(distinct = true,tables = "yh_shop_goods_sku ysgs left join goods_don g on g.id = ysgs.goods_id",
|
|
|
- where = "g.status = true and g.deleted = true")
|
|
|
+@SearchBean(tables = "yh_shop_goods_sku ysgs left join goods_don g on g.id = ysgs.goods_id" +
|
|
|
+ " left join goods_don_sku sku on sku.id = ysgs.sku_id",
|
|
|
+ where = "g.status = true and g.deleted = true"
|
|
|
+ , groupBy = "g.id,g.title,g.category,ysgs.status,ysgs.user_id")
|
|
|
public class YhShopGoodsView {
|
|
|
@DbField("g.id")
|
|
|
private Long goodsId;
|
|
|
@@ -31,6 +33,9 @@ public class YhShopGoodsView {
|
|
|
@DbField("ysgs.user_id")
|
|
|
private Long userId;
|
|
|
|
|
|
+ @DbField("group_concat(sku.spec_val,cast((ysgs.price/100) as decimal(10,2)),'元')")
|
|
|
+ private String skuDetail;
|
|
|
+
|
|
|
@DbIgnore
|
|
|
private List<YhShopGoodsSkuView> list;
|
|
|
|