From 0bf174be571c53b8af796eca4b51fcd3edec1657 Mon Sep 17 00:00:00 2001 From: DESKTOP-71BH0QO\L、ming <172680469@qq.com> Date: 星期日, 25 四月 2021 21:55:43 +0800 Subject: [PATCH] no --- springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComShopGoodsDAO.java | 11 ++++++----- 1 files changed, 6 insertions(+), 5 deletions(-) diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComShopGoodsDAO.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComShopGoodsDAO.java index 0cfaa0d..a0c350b 100644 --- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComShopGoodsDAO.java +++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComShopGoodsDAO.java @@ -27,8 +27,9 @@ @Select("<script>" + "select c.id,c.type_id,css.name as storeName,c.name,c.store_id,c.goods_pic,c.images,c.status,c.sale,c.original_price,c.price,c.unit,c.order,c.stock,c.details,c.remark,c.goods_describe,c.delivery_type,c.delete_status,c.create_at,c.update_at from com_shop_goods c \n" + - "right join com_shop_store css on c.store_id=css.id\n" + + " left join com_shop_store css on c.store_id=css.id\n" + " <where>" + + " and c.delete_status = 1 " + "<if test='pageComShopGoodsDTO.storeName != null and pageComShopGoodsDTO.storeName.trim() != ""'>" + "and css.name like concat('%',#{pageComShopGoodsDTO.storeName},'%') \n" + " </if> " + @@ -38,7 +39,6 @@ "<if test='pageComShopGoodsDTO.storeId != null'>" + "and css.id=#{pageComShopGoodsDTO.storeId} \n" + " </if> " + - "<if test='pageComShopGoodsDTO.status != null'>" + "and c.status like concat('%',#{pageComShopGoodsDTO.status},'%') \n" + " </if> " + @@ -68,10 +68,11 @@ * @return 商品列表 */ @Select("<script> " + - "select id,`name`,store_id,goods_pic,images,`status`,sale,original_price,price,unit" + - ",`order`,stock,details,delivery_type, create_at " + + "select csg.id,csg.`name`,csg.store_id,csg.goods_pic,csg.images,csg.`status`,csg.sale,csg.original_price " + + ",csg.price,csg.unit,csg.`order`,csg.stock,csg.details,csg.delivery_type, csg.create_at " + " from com_shop_goods as csg " + - " where 1=1 and csg.delete_status = 1 " + + " left join com_shop_store as css on css.id = csg.store_id " + + " where 1=1 and csg.delete_status = 1 and css.`status` = 1" + "<if test='comShopGoodsDTO.name != null and comShopGoodsDTO.name !=""'>" + " AND csg.`name` like concat('%',#{comShopGoodsDTO.name},'%') " + " </if> " + -- Gitblit v1.7.1