|
@@ -287,7 +287,6 @@ public class PlanController {
|
|
|
PlanPaperService.update(lambdaUpdatepaperWrapper);
|
|
|
|
|
|
planService.update(new LambdaUpdateWrapper<PlanDo>().set(PlanDo::getPublish,"c").in(PlanDo::getId,ids));
|
|
|
-
|
|
|
List<EmpCourseDo> toTestInfoList = empCourseService.list(new LambdaQueryWrapper<EmpCourseDo>()
|
|
|
.eq(BaseDo::getDeleted, "0")
|
|
|
.in(EmpCourseDo::getPlanid, ids)
|
|
@@ -297,10 +296,13 @@ public class PlanController {
|
|
|
if (toTestInfoList.isEmpty()) {
|
|
|
return R.ok();
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
- Map<String, List<String>> collect = toTestInfoList.stream().collect(Collectors.groupingBy(EmpCourseDo::getCoursename,
|
|
|
- Collectors.mapping(EmpCourseDo::getEmpid, Collectors.toList())));
|
|
|
+ Map<String, List<String>> collect = new HashMap<>();
|
|
|
+ planService.listByIds(ids).forEach(info->{
|
|
|
+ List<String> empIds = toTestInfoList.stream()
|
|
|
+ .filter(data -> data.getPlanid().equals(info.getId()))
|
|
|
+ .map(EmpCourseDo::getEmpid).collect(Collectors.toList());
|
|
|
+ collect.put(info.getCoursename(),empIds);
|
|
|
+ });
|
|
|
// 培训课程取消提醒
|
|
|
sendNotifyService.sendTrainingPlanCancelNotify(collect);
|
|
|
return R.ok();
|