分类 列表 数据问题
This commit is contained in:
parent
cab483a7b9
commit
5468fa56de
|
|
@ -38,7 +38,7 @@ public interface TbShopCategoryRepository extends JpaRepository<TbShopCategory,
|
|||
@Query("SELECT category FROM TbShopCategory category where category.tree IN :ids and category.id != category.tree")
|
||||
List<TbShopCategory> findChildren(@Param("ids")List<Integer> ids);
|
||||
|
||||
@Query(" SELECT category FROM TbShopCategory category where category.shopId = :shopId")
|
||||
@Query(" SELECT category FROM TbShopCategory category where category.shopId = :shopId and (category.pid is null or category.pid != '')")
|
||||
Page<TbShopCategory> findAllBy(@Param("shopId") String shopId,Pageable pageable);
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ public class TbShopCategoryServiceImpl implements TbShopCategoryService {
|
|||
.filter(d -> d.getTree()==null || d.getId().equals(d.getTree()))
|
||||
.collect(Collectors.toList());
|
||||
|
||||
return PageUtil.toPage(result, page.getTotalElements()-children.size());
|
||||
return PageUtil.toPage(result, page.getTotalElements());
|
||||
}
|
||||
|
||||
// @Override
|
||||
|
|
|
|||
Loading…
Reference in New Issue