Commit a59a8ca0 authored by liqin's avatar liqin 💬

bug fixed

parent 77516475
......@@ -608,9 +608,11 @@ public class ChinaMobileRestApiController extends BaseController {
.eq(LearningContent::getPublished, true).orderByDesc(LearningContent::getSortorder);
lambdaQueryWrapper.select(LearningContent::getName, LearningContent::getCover);
List<LearningContent> learningContentList = this.learningContentService.list(lambdaQueryWrapper);
String learningContentNames = learningContentList.stream().map(LearningContent::getName).collect(Collectors.joining("、"));
learningProject.setThumbnail(learningContentList.get(0).getCover());
learningProject.setLearningContentNames(learningContentNames);
if (!learningContentList.isEmpty()) {
String learningContentNames = learningContentList.stream().map(LearningContent::getName).collect(Collectors.joining("、"));
learningProject.setThumbnail(learningContentList.get(0).getCover());
learningProject.setLearningContentNames(learningContentNames);
}
}
return getResult(page);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment