太湖英才可绑定课程列表 修改
This commit is contained in:
@@ -56,15 +56,11 @@ public class TaihuTalentController {
|
||||
//太湖英才可绑定课程列表
|
||||
@RequestMapping("/getCourseListCanTalent")
|
||||
public R getCourseListCanTalent(@RequestBody Map<String,Object> params){
|
||||
List<Integer> collect = courseToTalentService.list(new LambdaQueryWrapper<CourseToTalent>()
|
||||
.eq(CourseToTalent::getTalentId, params.get("talentId")))
|
||||
.stream().map(CourseToTalent::getCourseId).collect(Collectors.toList());
|
||||
MPJLambdaWrapper<CourseEntity> wrapper = new MPJLambdaWrapper<>();
|
||||
wrapper.rightJoin(CourseToTaihumed.class,CourseToTaihumed::getCourseId,CourseEntity::getId);
|
||||
wrapper.selectAll(CourseEntity.class);
|
||||
if (collect.size() != 0){
|
||||
wrapper.notIn(CourseEntity::getId,collect);
|
||||
}
|
||||
String sql = "select 1 from course_to_talent where del_flag = 0 and course_id = t1.course_id and talent_id = "+params.get("talentId");
|
||||
wrapper.notExists(sql);
|
||||
wrapper.like(StringUtils.isNotBlank(params.get("title").toString()),CourseEntity::getTitle,params.get("title"));
|
||||
Page<CourseEntity> page = courseService.page(new Page<>(Long.parseLong(params.get("current").toString()),
|
||||
Long.parseLong(params.get("limit").toString())), wrapper);
|
||||
|
||||
Reference in New Issue
Block a user