|
|
|
@@ -228,7 +228,7 @@ public class WxMerchantServiceImpl implements WxMerchantService { |
|
|
|
@Override |
|
|
|
public PageInfo<WxMerchantVo> listAsPageCVo(WxMerchantDto wxMerchantDto, Integer pageIndex, Integer pageSize,boolean hasShop) { |
|
|
|
if (null != wxMerchantDto.getBuilding() || null != wxMerchantDto.getFloor()) { |
|
|
|
List<Long> merchantIds = getFloorBuildMerchantIds(wxMerchantDto, null, wxMerchantDto.getBuilding(), wxMerchantDto.getFloor(), null, null,null); |
|
|
|
List<Long> merchantIds = getFloorBuildMerchantIds(wxMerchantDto, null, wxMerchantDto.getBuilding(), wxMerchantDto.getFloor(),null, null, null,null); |
|
|
|
wxMerchantDto.setIds(merchantIds); |
|
|
|
} |
|
|
|
if(wxMerchantDto.getIsAdmin() == null){ |
|
|
|
@@ -1067,7 +1067,7 @@ public class WxMerchantServiceImpl implements WxMerchantService { |
|
|
|
} |
|
|
|
|
|
|
|
if (null != wxMerchant.getFloorForRule() || null != wxMerchant.getBuilding() || null != wxMerchant.getFloor()) { |
|
|
|
List<Long> floorMerchantIds = getFloorBuildingMerchantIds(wxMerchant,wxMerchant.getFloorForRule(),wxMerchant.getBuilding(),wxMerchant.getFloor()); |
|
|
|
List<Long> floorMerchantIds = getFloorBuildingMerchantIds(wxMerchant,wxMerchant.getFloorForRule(),wxMerchant.getBuilding(),wxMerchant.getFloor(),wxMerchant.getShopTypeForRule()); |
|
|
|
if (null != floorMerchantIds && floorMerchantIds.size() > 0 ) { |
|
|
|
wxMerchant.setIds(floorMerchantIds); |
|
|
|
}else { |
|
|
|
@@ -1273,7 +1273,7 @@ public class WxMerchantServiceImpl implements WxMerchantService { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
List<Long> floorMerchantIds = getFloorBuildingMerchantIds(record,record.getFloorForRule(),record.getBuilding(),record.getFloor()); |
|
|
|
List<Long> floorMerchantIds = getFloorBuildingMerchantIds(record,record.getFloorForRule(),record.getBuilding(),record.getFloor(),record.getShopTypeForRule()); |
|
|
|
if(floorMerchantIds != null){ |
|
|
|
if(merchantIds.size() > 0){ |
|
|
|
merchantIds.retainAll(floorMerchantIds); |
|
|
|
@@ -1322,14 +1322,14 @@ public class WxMerchantServiceImpl implements WxMerchantService { |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
private List<Long> getFloorBuildingMerchantIds(TenantEntity tenantEntity,String floorForRule,Long buildingId,Long floor) { |
|
|
|
private List<Long> getFloorBuildingMerchantIds(TenantEntity tenantEntity,String floorForRule,Long buildingId,Long floor,String shopTypeForRule) { |
|
|
|
String floorRule = StringUtils.trimToNull(floorForRule); |
|
|
|
List<Long> floorMerchantIds = getFloorBuildMerchantIds(tenantEntity, floorRule, buildingId, floor, 0, 0,null); |
|
|
|
List<Long> floorMerchantIds = getFloorBuildMerchantIds(tenantEntity, floorRule, buildingId, floor,shopTypeForRule, 0, 0,null); |
|
|
|
return floorMerchantIds; |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public List<Long> getFloorBuildMerchantIds(TenantEntity tenantEntity,String floorRule,Long building,Long floor,Integer merchantShopDel,Integer shopDel,String shopNumber ) { |
|
|
|
public List<Long> getFloorBuildMerchantIds(TenantEntity tenantEntity,String floorRule,Long building,Long floor,String shopTypeForRule,Integer merchantShopDel,Integer shopDel,String shopNumber ) { |
|
|
|
if (null != floorRule || null != building || null != floor) { |
|
|
|
List<Long> floorMerchantIds = null; |
|
|
|
WxShop shopQ = new WxShop(); |
|
|
|
@@ -1346,6 +1346,9 @@ public class WxMerchantServiceImpl implements WxMerchantService { |
|
|
|
if (null != floor) { |
|
|
|
shopQ.setFloor(floor); |
|
|
|
} |
|
|
|
if (null != shopTypeForRule) { |
|
|
|
shopQ.setShopTypeForRule(shopTypeForRule); |
|
|
|
} |
|
|
|
shopQ.setShopNumber(shopNumber); |
|
|
|
List<Long> shopIds = wxShopMapper.findIdList(shopQ); |
|
|
|
if (null == shopIds || shopIds.size() <= 0) { |
|
|
|
|