|
@@ -155,4 +155,13 @@ public class CourseApi {
|
|
courseService.enableCourse(courseIds,false);
|
|
courseService.enableCourse(courseIds,false);
|
|
return new ResponseEntity(HttpStatus.OK);
|
|
return new ResponseEntity(HttpStatus.OK);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ @ApiOperation(value="启用课程",notes="启用")
|
|
|
|
+ @PutMapping("/enable/{ids}")
|
|
|
|
+ public ResponseEntity enableCourse(@PathVariable String ids){
|
|
|
|
+ List<Long> courseIds = Stream.of(ids.split(",")).map(s->Long.parseLong(s.trim()))
|
|
|
|
+ .collect(Collectors.toList());
|
|
|
|
+ courseService.enableCourse(courseIds,true);
|
|
|
|
+ return new ResponseEntity(HttpStatus.OK);
|
|
|
|
+ }
|
|
}
|
|
}
|