Commit 18f61d97 authored by xuxin's avatar xuxin

未绑定ip的店铺

parent d3e5d284
......@@ -407,15 +407,14 @@ public class ShopServiceImpl implements ShopService {
List<String> shopIds = null;
if (shopFilterDto.getBindIp() == 0) {
shopIds = allIds;
// 这个地方有点奇怪,为啥不去 userShop 中找,而是在 ipresource 中找? 可以查看下删除绑定状态的逻辑
} else if (shopFilterDto.getBindIp() == 1) {
// ip资源已经分配了 的店铺
}
// 绑定了 ip 资源的店铺
if (shopFilterDto.getBindIp() == 1) {
shopIds = ipResourceRepository.findShopIdInList(allIds, false).stream()
.flatMap((x -> x.getShopIds().stream())).collect(Collectors.toList());
// 这个地方的其他情况是指什么情况
} else {
}
// 未绑定 ip 资源的店铺
if (shopFilterDto.getBindIp() == 2) {
// 店铺绑定的 ip 资源被删除的 店铺
for (String id : allIds) {
IpResource ipResource = ipResourceRepository.findFirstByShopIdsIsAndIsDeleted(id, true);
......@@ -425,6 +424,14 @@ public class ShopServiceImpl implements ShopService {
}
}
// 临时试用一下
if (shopFilterDto.getBindIp() == 3) {
List<String> shopIds2 = ipResourceRepository.findShopIdInList(allIds, false).stream()
.flatMap((x -> x.getShopIds().stream())).collect(Collectors.toList());
allIds.removeAll(shopIds2);
shopIds = allIds;
}
amount = amount > 100 ? 100 : amount;
Pageable pageable = PageRequest.of(pageNum, amount);
// 5. 根据过滤后的商铺ids 与 其他过滤条件 得到商铺信息并分页
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment