liu 9 kuukautta sitten
vanhempi
commit
9187cc54f8

+ 2 - 0
src/main/java/com/sqx/modules/goods/entity/GoodsShop.java

@@ -7,6 +7,8 @@ import com.baomidou.mybatisplus.annotation.TableField;
 import com.baomidou.mybatisplus.annotation.TableId;
 import com.sqx.modules.activity.vo.ShopActivityVO;
 import com.sqx.modules.coupon.entity.TbCoupon;
+import com.sqx.modules.goods.vo.ShopTypeVo;
+import com.sqx.modules.shop.entity.ShopType;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;

+ 14 - 0
src/main/java/com/sqx/modules/goods/vo/ShopTypeVo.java

@@ -0,0 +1,14 @@
+package com.sqx.modules.goods.vo;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+@Data
+public class ShopTypeVo {
+    @ApiModelProperty("主键id")
+    private Integer shopTypeId;
+
+
+    @ApiModelProperty("主营业务类型")
+    private String shopTypeName;
+}

+ 2 - 2
src/main/resources/mapper/goods/GoodsShopMapper.xml

@@ -237,7 +237,7 @@
             and gs.activity_id = #{activityId}
         </if>
         <if test="shopTypeId!=null">
-            and gs.shop_type_id = #{shopTypeId}
+            and  FIND_IN_SET(#{shopTypeId},gs.shop_type_id)
         </if>
         order by gs.is_recommend desc
         <if test="screen==1">
@@ -517,7 +517,7 @@
             and gs.activity_id = #{activityId}
         </if>
         <if test="shopTypeId!=null">
-            and gs.shop_type_id = #{shopTypeId}
+            and FIND_IN_SET(#{shopTypeId},gs.shop_type_id)
         </if>
         order by gs.is_recommend desc
         <if test="screen==1">