|
@@ -85,19 +85,20 @@ public class AlbumCategoryServiceImpl extends SuperServiceImpl<AlbumCategoryMapp
|
|
|
if (param.containsKey("name")){
|
|
|
//一级分类信息
|
|
|
List<AlbumCategoryVo> allAlbumCategory1 = albumCategoryMapper.findAllAlbumCategory1(queryFilter.getParams(), params);
|
|
|
- if (CollectionUtils.isEmpty(allAlbumCategory1)){
|
|
|
- return page;
|
|
|
- }
|
|
|
List<String> childIdList = findChild(allAlbumCategory1, true);
|
|
|
//查询符合条件的二级分类
|
|
|
List<AlbumCategoryVo> allAlbumCategory2 = albumCategoryMapper.findAllAlbumCategory2(queryFilter.getParams(), params);
|
|
|
if (CollectionUtils.isNotEmpty(allAlbumCategory2)){
|
|
|
allAlbumCategory2.forEach(albumCategoryVo2 -> {
|
|
|
- if (CollectionUtils.isNotEmpty(childIdList) && !childIdList.contains(albumCategoryVo2.getPkId())){
|
|
|
+ if (!childIdList.contains(albumCategoryVo2.getPkId())){
|
|
|
+ albumCategoryVo2.setOperator(userService.queryUser(albumCategoryVo2.getUpdateBy()).getFullName());
|
|
|
allAlbumCategory1.add(albumCategoryVo2);
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
+ if (CollectionUtils.isEmpty(allAlbumCategory1)){
|
|
|
+ return page;
|
|
|
+ }
|
|
|
return PageListUtils.getPages(queryFilter.getPage().getCurrent(), queryFilter.getPage().getSize(),allAlbumCategory1);
|
|
|
} else {
|
|
|
//查询一级分类下的二级分类
|