winter 1 год назад
Родитель
Сommit
f02f502762
3 измененных файлов: 18 добавлений и 11 удалений
  1. +4
    -3
      mallinkAdmin/src/main/java/com/iformall/controller/basic/WxShopController.java
  2. +3
    -1
      mallinkService/src/main/java/com/iformall/domain/po/WxShop.java
  3. +11
    -7
      mallinkService/src/main/resources/mapper/WxShopMapper.xml

+ 4
- 3
mallinkAdmin/src/main/java/com/iformall/controller/basic/WxShopController.java Просмотреть файл

@@ -102,11 +102,12 @@ public class WxShopController extends BaseController {
suq.setSearchKey(wxShop.getSearchKey());
List<Long> shopIdList = wxShopService.getUserShopIds(suq);
if (null != shopIdList && shopIdList.size() <= 0 ) {
wxShop.setId(-1L);
wxShop.setSearchKeyShopNumber(wxShop.getSearchKey());
}else {
wxShop.setOrShopIds(shopIdList);
wxShop.setSearchKeyShopIds(shopIdList);
wxShop.setSearchKeyShopNumber(wxShop.getSearchKey());
}
wxShop.setShopNumber(wxShop.getSearchKey());
}
final PageInfo<WxShop> page = wxShopService.listAsPage(wxShop, pageNum, pageSize);
return new ResultData(page);


+ 3
- 1
mallinkService/src/main/java/com/iformall/domain/po/WxShop.java Просмотреть файл

@@ -229,7 +229,9 @@ public class WxShop extends TenantEntity {
@TableField(exist = false)
private String searchKey;
@TableField(exist = false)
private List<Long> orShopIds;
private List<Long> searchKeyShopIds;
@TableField(exist = false)
private String searchKeyShopNumber;
@TableField(exist = false)
private Integer shopUserType;
@TableField(exist = false)


+ 11
- 7
mallinkService/src/main/resources/mapper/WxShopMapper.xml Просмотреть файл

@@ -154,13 +154,17 @@
</foreach>
</if>
<if test=" null != orShopIds ">
and (id in
<foreach collection="orShopIds" index="index" item="oridItem" open="(" separator="," close=")">
#{oridItem}
</foreach>
or `shop_number` like concat('%', #{shopNumber},'%'))
</if>
<if test=" null != searchKeyShopNumber and '' != searchKeyShopNumber ">
and (`shop_number` like concat('%', #{searchKeyShopNumber},'%')
<if test=" null != searchKeyShopIds ">
or id in
<foreach collection="searchKeyShopIds" index="index" item="oridItem" open="(" separator="," close=")">
#{oridItem}
</foreach>
</if>
)
</if>

<if test=" null != ids ">
and id in


Загрузка…
Отмена
Сохранить