Browse Source

Merge branch 'dev_voice' of http://git.elinkit.com.cn:7070/r/epmet-cloud into dev_voice

dev_shibei_match
jianjun 5 years ago
parent
commit
9c48afcf10
  1. 7
      epmet-module/resi-voice/resi-voice-server/src/main/java/com/epmet/service/impl/ArticleServiceImpl.java

7
epmet-module/resi-voice/resi-voice-server/src/main/java/com/epmet/service/impl/ArticleServiceImpl.java

@ -68,7 +68,10 @@ public class ArticleServiceImpl implements ArticleService {
@Override @Override
public List<ArticleWithTagsResultDTO> articleList(ArticlePageFormDTO articlePageFormDTO) { public List<ArticleWithTagsResultDTO> articleList(ArticlePageFormDTO articlePageFormDTO) {
Result<List<ArticleListResultDTO>> articles = govVoiceOpenFeignClient.resiArticleList(articlePageFormDTO); Result<List<ArticleListResultDTO>> articles = govVoiceOpenFeignClient.resiArticleList(articlePageFormDTO);
if(articles.success() && null != articles.getData() && articles.getData().size() > NumConstant.ZERO){ if(articles.success()){
if(null == articles.getData() || articles.getData().size() <= NumConstant.ZERO){
return new ArrayList<>();
}
return articles.getData().stream().map(article -> { return articles.getData().stream().map(article -> {
ArticleWithTagsResultDTO artObj = ConvertUtils.sourceToTarget(article,ArticleWithTagsResultDTO.class); ArticleWithTagsResultDTO artObj = ConvertUtils.sourceToTarget(article,ArticleWithTagsResultDTO.class);
artObj.setTagName(new HashSet<>()); artObj.setTagName(new HashSet<>());
@ -83,7 +86,7 @@ public class ArticleServiceImpl implements ArticleService {
} }
return new ArrayList<>(); throw new RenException(articles.getInternalMsg());
} }
} }

Loading…
Cancel
Save