|
@@ -8,6 +8,7 @@ import com.diagbot.enums.LexiconTypeEnum;
|
|
|
import com.diagbot.service.impl.RelationServiceImpl;
|
|
|
import com.diagbot.util.ListUtil;
|
|
|
import com.diagbot.util.RespDTOUtil;
|
|
|
+import com.diagbot.util.StringUtil;
|
|
|
import com.diagbot.vo.OnlyByRootListVO;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Component;
|
|
@@ -38,16 +39,19 @@ public class MultContactFacade extends RelationServiceImpl {
|
|
|
|
|
|
if (ListUtil.isNotEmpty(ipage.getRecords())) {
|
|
|
List<String> userIds = ipage.getRecords()
|
|
|
- .stream().map(i -> i.getOperName()).distinct().collect(Collectors.toList());
|
|
|
- RespDTO<Map<String, String>> respDTO = userServiceClient.getUserInfoByIds(userIds);
|
|
|
- RespDTOUtil.respNGDealCover(respDTO, "获取用户信息失败");
|
|
|
-
|
|
|
- ipage.getRecords().forEach(i -> {
|
|
|
- i.setOperName(respDTO.data.get(i.getOperName()));
|
|
|
- i.setLibType(LexiconTypeEnum.getName(i.getLibTypeId().intValue()));
|
|
|
- i.setLibNameType(i.getLibName() + "(" + i.getLibType() + ")");
|
|
|
-
|
|
|
- });
|
|
|
+ .stream().filter(i -> StringUtil.isNotBlank(i.getOperName()))
|
|
|
+ .map(i -> i.getOperName()).distinct().collect(Collectors.toList());
|
|
|
+
|
|
|
+ if (ListUtil.isNotEmpty(userIds)) {
|
|
|
+ RespDTO<Map<String, String>> respDTO = userServiceClient.getUserInfoByIds(userIds);
|
|
|
+ RespDTOUtil.respNGDealCover(respDTO, "获取用户信息失败");
|
|
|
+
|
|
|
+ ipage.getRecords().forEach(i -> {
|
|
|
+ i.setOperName(respDTO.data.get(i.getOperName()));
|
|
|
+ i.setLibType(LexiconTypeEnum.getName(i.getLibTypeId().intValue()));
|
|
|
+ i.setLibNameType(i.getLibName() + "(" + i.getLibType() + ")");
|
|
|
+ });
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
return ipage;
|