|
@@ -247,21 +247,20 @@ public class ConceptFacade extends ConceptServiceImpl {
|
|
|
public IPage<GetAllInformationDTO> getAllInformation(GetAllInformationVO getAllInformationVO) {
|
|
|
Page<GetAllInformationDTO> getAllInformationDTOPage = new Page<>();
|
|
|
|
|
|
- List<Long> conceptIdList = null;
|
|
|
- if(StringUtil.isBlank(getAllInformationVO.getLibName())&&StringUtil.isNotBlank(getAllInformationVO.getName())){
|
|
|
- getAllInformationVO.setLibName(getAllInformationVO.getName());
|
|
|
- }
|
|
|
+ Page<Concept> conceptPage = new Page<>(getAllInformationVO.getCurrent(),getAllInformationVO.getSize());
|
|
|
+ QueryWrapper<Concept> conceptQe = new QueryWrapper<>();
|
|
|
if(StringUtil.isNotBlank(getAllInformationVO.getLibName())){
|
|
|
QueryWrapper<LibraryInfo> libraryInfoQe = new QueryWrapper<>();
|
|
|
libraryInfoQe.eq("is_deleted", IsDeleteEnum.N.getKey());
|
|
|
libraryInfoQe.like("name", getAllInformationVO.getLibName());
|
|
|
libraryInfoQe.eq(StringUtil.isNotBlank(getAllInformationVO.getType()),"type_id", LexiconTypeEnum.getKey(getAllInformationVO.getType()));
|
|
|
- conceptIdList = libraryinfoFacade.list(libraryInfoQe).stream().map(i->i.getConceptId()).distinct().collect(Collectors.toList());
|
|
|
+ List<Long> conceptIdList = libraryinfoFacade.list(libraryInfoQe).stream().map(i->i.getConceptId()).distinct().collect(Collectors.toList());
|
|
|
+ if(ListUtil.isNotEmpty(conceptIdList)){
|
|
|
+ conceptQe.in("id", conceptIdList);
|
|
|
+ }else{
|
|
|
+ conceptQe.eq("id", -999999999);
|
|
|
+ }
|
|
|
}
|
|
|
-
|
|
|
- Page<Concept> conceptPage = new Page<>(getAllInformationVO.getCurrent(),getAllInformationVO.getSize());
|
|
|
- QueryWrapper<Concept> conceptQe = new QueryWrapper<>();
|
|
|
- conceptQe.in(ListUtil.isNotEmpty(conceptIdList), "id", conceptIdList);
|
|
|
conceptQe.like(StringUtil.isNotBlank(getAllInformationVO.getName()),"lib_name", getAllInformationVO.getName());
|
|
|
conceptQe.eq(StringUtil.isNotBlank(getAllInformationVO.getType()),"lib_type", LexiconTypeEnum.getKey(getAllInformationVO.getType()));
|
|
|
conceptQe.eq(StringUtil.isNotBlank(getAllInformationVO.getIsDeleted()),"is_deleted", getAllInformationVO.getIsDeleted());
|