|
@@ -2,6 +2,7 @@ package com.yonge.cooleshow.biz.dal.service.impl;
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
|
+import com.google.common.collect.Lists;
|
|
|
import com.yonge.cooleshow.biz.dal.dao.CourseScheduleDao;
|
|
|
import com.yonge.cooleshow.biz.dal.dao.StudentDao;
|
|
|
import com.yonge.cooleshow.biz.dal.dao.SubjectDao;
|
|
@@ -117,7 +118,10 @@ public class UserBindingTeacherServiceImpl extends ServiceImpl<UserBindingTeache
|
|
|
subjectIdList.add(aLong);
|
|
|
}
|
|
|
}
|
|
|
- List<Subject> subjectList = subjectDao.findBySubjectIds(subjectIdList);
|
|
|
+ List<Subject> subjectList = Lists.newArrayList();
|
|
|
+ if (org.apache.commons.collections.CollectionUtils.isNotEmpty(subjectIdList)) {
|
|
|
+ subjectList.addAll(subjectDao.findBySubjectIds(subjectIdList));
|
|
|
+ }
|
|
|
Map<Long, String> userIdSubjectMap = students.stream()
|
|
|
.filter(x -> StringUtils.isNotBlank(x.getSubjectId()))
|
|
|
.collect(Collectors.toMap(Student::getUserId,student -> subjectList.stream()
|