一、讲师管理

1、新增讲师

接口url:/eduservice/teacher/addTeacher
请求方式:post
请求参数:

  1. public class TeacherVo implements Serializable {
  2. private static final long serialVersionUID = 1L;
  3. @ApiModelProperty(value = "讲师姓名")
  4. private String name;
  5. @ApiModelProperty(value = "讲师简介")
  6. private String intro;
  7. @ApiModelProperty(value = "讲师资历,一句话说明讲师")
  8. private String career;
  9. @ApiModelProperty(value = "头衔 1高级讲师 2首席讲师")
  10. private Integer level;
  11. @ApiModelProperty(value = "讲师头像")
  12. private String avatar;
  13. @ApiModelProperty(value = "排序")
  14. private Integer sort;
  15. }

响应参数:

  1. {
  2. "success":true,
  3. "code":20000,
  4. "message":"成功",
  5. "data":{}
  6. }

2、编辑讲师

请求地址:/eduservice/teacher/updateTeacher
请求方式:post
请求参数:

  1. public class EduTeacher implements Serializable {
  2. private static final long serialVersionUID = 1L;
  3. @ApiModelProperty(value = "讲师ID")
  4. @TableId(value = "id", type = IdType.ID_WORKER_STR)
  5. private String id;
  6. @ApiModelProperty(value = "讲师姓名")
  7. private String name;
  8. @ApiModelProperty(value = "讲师简介")
  9. private String intro;
  10. @ApiModelProperty(value = "讲师资历,一句话说明讲师")
  11. private String career;
  12. @ApiModelProperty(value = "头衔 1高级讲师 2首席讲师")
  13. private Integer level;
  14. @ApiModelProperty(value = "讲师头像")
  15. private String avatar;
  16. @ApiModelProperty(value = "排序")
  17. private Integer sort;
  18. @ApiModelProperty(value = "逻辑删除 1(true)已删除, 0(false)未删除")
  19. @TableLogic
  20. private Boolean isDeleted;
  21. @ApiModelProperty(value = "创建时间")
  22. @TableField(fill = FieldFill.INSERT)
  23. private Date gmtCreate;
  24. @ApiModelProperty(value = "更新时间")
  25. @TableField(fill = FieldFill.INSERT_UPDATE)
  26. private Date gmtModified;
  27. }

响应参数:

  1. {
  2. "success":true,
  3. "code":20000,
  4. "message":"成功",
  5. "data":{}
  6. }

3、删除讲师

请求url:/eduservice/teacher/{id}
请求方式:delete
请求参数:
响应参数:

  1. {
  2. "success":true,
  3. "code":20000,
  4. "message":"成功",
  5. "data":{}
  6. }

4、讲师列表查询

请求url:/eduservice/teacher/pageTeacherCondition/{current}/{limit}
请求方式:get
请求参数:

  1. @Data
  2. public class TeacherQuery {
  3. @ApiModelProperty(value = "教师名称,模糊查询")
  4. private String name;
  5. @ApiModelProperty(value = "头衔 1高级讲师 2首席讲师")
  6. private Integer level;
  7. @ApiModelProperty(value = "查询开始时间", example = "2019-01-01 10:10:10")
  8. private String begin;//注意,这里使用的是String类型,前端传过来的数据无需进行类型转换
  9. @ApiModelProperty(value = "查询结束时间", example = "2019-12-01 10:10:10")
  10. private String end;
  11. }

响应参数:

  1. public class TeacherResp implements Serializable {
  2. private static final long serialVersionUID = 1L;
  3. @ApiModelProperty(value = "讲师ID")
  4. @TableId(value = "id", type = IdType.ID_WORKER_STR)
  5. private String id;
  6. @ApiModelProperty(value = "讲师姓名")
  7. private String name;
  8. @ApiModelProperty(value = "讲师资历,一句话说明讲师")
  9. private String career;
  10. @ApiModelProperty(value = "头衔 1高级讲师 2首席讲师")
  11. private Integer level;
  12. @ApiModelProperty(value = "排序")
  13. private Integer sort;
  14. @ApiModelProperty(value = "逻辑删除 1(true)已删除, 0(false)未删除")
  15. @TableLogic
  16. private Boolean isDeleted;
  17. @ApiModelProperty(value = "创建时间")
  18. @TableField(fill = FieldFill.INSERT)
  19. private Date gmtCreate;
  20. }

5、讲师详情查询

请求url:/eduservice/teachergetTeacher/{id}
请求方式:get
请求参数:
响应参数:

  1. public class EduTeacher implements Serializable {
  2. private static final long serialVersionUID = 1L;
  3. @ApiModelProperty(value = "讲师ID")
  4. @TableId(value = "id", type = IdType.ID_WORKER_STR)
  5. private String id;
  6. @ApiModelProperty(value = "讲师姓名")
  7. private String name;
  8. @ApiModelProperty(value = "讲师简介")
  9. private String intro;
  10. @ApiModelProperty(value = "讲师资历,一句话说明讲师")
  11. private String career;
  12. @ApiModelProperty(value = "头衔 1高级讲师 2首席讲师")
  13. private Integer level;
  14. @ApiModelProperty(value = "讲师头像")
  15. private String avatar;
  16. @ApiModelProperty(value = "排序")
  17. private Integer sort;
  18. @ApiModelProperty(value = "逻辑删除 1(true)已删除, 0(false)未删除")
  19. @TableLogic
  20. private Boolean isDeleted;
  21. @ApiModelProperty(value = "创建时间")
  22. @TableField(fill = FieldFill.INSERT)
  23. private Date gmtCreate;
  24. @ApiModelProperty(value = "更新时间")
  25. @TableField(fill = FieldFill.INSERT_UPDATE)
  26. private Date gmtModified;
  27. }

二、课程分类

1、导入课程分类

请求url:/eduservice/subject/addSubject
请求方式:post
请求参数:

  1. MultipartFile file

响应参数:

2、课程分类列表查询-树形结构

请求url:/eduservice/subject/getAllSubject
请求方式:get
请求参数:无
响应参数:

  1. {
  2. "success": true,
  3. "code": 20000,
  4. "message": "成功",
  5. "data": {
  6. "list": [{
  7. "id": "1178214681118568449",
  8. "title": "后端开发",
  9. "children": [{
  10. "id": "1178214681139539969",
  11. "title": "Java"
  12. }, {
  13. "id": "1178585108407984130",
  14. "title": "Python"
  15. }, {
  16. "id": "1433788723642335233",
  17. "title": "c++"
  18. }]
  19. }, {
  20. "id": "1178214681181483010",
  21. "title": "前端开发",
  22. "children": [{
  23. "id": "1178214681210843137",
  24. "title": "JavaScript"
  25. }, {
  26. "id": "1178585108454121473",
  27. "title": "HTML/CSS"
  28. }, {
  29. "id": "1433788723554254849",
  30. "title": "vue"
  31. }, {
  32. "id": "1433788723604586497",
  33. "title": "jquery"
  34. }]
  35. }]
  36. }
  37. }

三、课程管理

1、课程基本信息

1.1 添加课程基本信息

请求url:/eduservice/course/addCourseInfo
请求方式:post
请求参数:

  1. package com.atguigu.eduservice.entity.vo;
  2. @Data
  3. public class CourseInfoVo {
  4. @ApiModelProperty(value = "课程ID")
  5. private String id;
  6. @ApiModelProperty(value = "课程讲师ID")
  7. private String teacherId;
  8. @ApiModelProperty(value = "课程专业ID")
  9. private String subjectId;
  10. @ApiModelProperty(value = "一级分类级ID")
  11. private String subjectParentId;
  12. @ApiModelProperty(value = "课程标题")
  13. private String title;
  14. @ApiModelProperty(value = "课程销售价格,设置为0则可免费观看")
  15. // 0.01
  16. private BigDecimal price;
  17. @ApiModelProperty(value = "总课时")
  18. private Integer lessonNum;
  19. @ApiModelProperty(value = "课程封面图片路径")
  20. private String cover;
  21. @ApiModelProperty(value = "课程简介")
  22. private String description;
  23. }

响应参数:

1.2 编辑课程基本信息

请求url:/eduservice/course/updateCourseInfo
请求方式:post
请求参数:

  1. package com.atguigu.eduservice.entity.vo;
  2. @Data
  3. public class CourseInfoVo {
  4. @ApiModelProperty(value = "课程ID")
  5. private String id;
  6. @ApiModelProperty(value = "课程讲师ID")
  7. private String teacherId;
  8. @ApiModelProperty(value = "课程专业ID")
  9. private String subjectId;
  10. @ApiModelProperty(value = "一级分类级ID")
  11. private String subjectParentId;
  12. @ApiModelProperty(value = "课程标题")
  13. private String title;
  14. @ApiModelProperty(value = "课程销售价格,设置为0则可免费观看")
  15. // 0.01
  16. private BigDecimal price;
  17. @ApiModelProperty(value = "总课时")
  18. private Integer lessonNum;
  19. @ApiModelProperty(value = "课程封面图片路径")
  20. private String cover;
  21. @ApiModelProperty(value = "课程简介")
  22. private String description;
  23. }

响应参数:

1.3 查看课程基本信息

请求url:/eduservice/course/getCourseInfo/{courseId}
请求方式:get
请求参数:
响应参数:

2、课程大纲

2.1 根据课程ID查看课程大纲信息

请求url:/eduservice/chapter/getChapterVideo/{courseId}
请求方式:get
请求参数:
响应参数:

2.2 编辑课程大纲信息11

请求url:/eduservice/course/{current}/{limit}
请求方式:post
请求参数:
响应参数:

3、课程章节

3.1 新增章节

请求url:/eduservice/chapter/addChapter
请求方式:post
请求参数:
响应参数:

3.2 编辑章节

请求url:/eduservice/chapter/updateChapter
请求方式:post
请求参数:
响应参数:

3.3 根据章节ID查询详情

请求url:/eduservice/chapter/getChapterInfo/{chapterId}
请求方式:get
请求参数:
响应参数:

3.4 删除章节

请求url:/eduservice/chapter/{chapterId}
请求方式:delete
请求参数:
响应参数:

4、课程小节

4.1 新增小节

请求url:/eduservice/video/addVideo
请求方式:post
请求参数:

  1. package com.atguigu.eduservice.entity;
  2. @Data
  3. @EqualsAndHashCode(callSuper = false)
  4. @Accessors(chain = true)
  5. @ApiModel(value="EduVideo对象", description="课程视频")
  6. public class EduVideo implements Serializable {
  7. private static final long serialVersionUID = 1L;
  8. @ApiModelProperty(value = "视频ID")
  9. @TableId(value = "id", type = IdType.ID_WORKER_STR)
  10. private String id;
  11. @ApiModelProperty(value = "课程ID")
  12. private String courseId;
  13. @ApiModelProperty(value = "章节ID")
  14. private String chapterId;
  15. @ApiModelProperty(value = "节点名称")
  16. private String title;
  17. @ApiModelProperty(value = "云端视频资源")
  18. private String videoSourceId;
  19. @ApiModelProperty(value = "原始文件名称")
  20. private String videoOriginalName;
  21. @ApiModelProperty(value = "排序字段")
  22. private Integer sort;
  23. @ApiModelProperty(value = "播放次数")
  24. private Long playCount;
  25. @ApiModelProperty(value = "是否可以试听:0收费 1免费")
  26. private Boolean isFree;
  27. @ApiModelProperty(value = "视频时长(秒)")
  28. private Float duration;
  29. @ApiModelProperty(value = "Empty未上传 Transcoding转码中 Normal正常")
  30. private String status;
  31. @ApiModelProperty(value = "视频源文件大小(字节)")
  32. private Long size;
  33. @ApiModelProperty(value = "乐观锁")
  34. private Long version;
  35. @ApiModelProperty(value = "创建时间")
  36. @TableField(fill = FieldFill.INSERT)
  37. private Date gmtCreate;
  38. @ApiModelProperty(value = "更新时间")
  39. @TableField(fill = FieldFill.INSERT_UPDATE)
  40. private Date gmtModified;
  41. }

响应参数:

4.2 编辑小节

请求url:/eduservice/video/updateVideo
请求方式:post
请求参数:

  1. package com.atguigu.eduservice.entity;
  2. @Data
  3. @EqualsAndHashCode(callSuper = false)
  4. @Accessors(chain = true)
  5. @ApiModel(value="EduVideo对象", description="课程视频")
  6. public class EduVideo implements Serializable {
  7. private static final long serialVersionUID = 1L;
  8. @ApiModelProperty(value = "视频ID")
  9. @TableId(value = "id", type = IdType.ID_WORKER_STR)
  10. private String id;
  11. @ApiModelProperty(value = "课程ID")
  12. private String courseId;
  13. @ApiModelProperty(value = "章节ID")
  14. private String chapterId;
  15. @ApiModelProperty(value = "节点名称")
  16. private String title;
  17. @ApiModelProperty(value = "云端视频资源")
  18. private String videoSourceId;
  19. @ApiModelProperty(value = "原始文件名称")
  20. private String videoOriginalName;
  21. @ApiModelProperty(value = "排序字段")
  22. private Integer sort;
  23. @ApiModelProperty(value = "播放次数")
  24. private Long playCount;
  25. @ApiModelProperty(value = "是否可以试听:0收费 1免费")
  26. private Boolean isFree;
  27. @ApiModelProperty(value = "视频时长(秒)")
  28. private Float duration;
  29. @ApiModelProperty(value = "Empty未上传 Transcoding转码中 Normal正常")
  30. private String status;
  31. @ApiModelProperty(value = "视频源文件大小(字节)")
  32. private Long size;
  33. @ApiModelProperty(value = "乐观锁")
  34. private Long version;
  35. @ApiModelProperty(value = "创建时间")
  36. @TableField(fill = FieldFill.INSERT)
  37. private Date gmtCreate;
  38. @ApiModelProperty(value = "更新时间")
  39. @TableField(fill = FieldFill.INSERT_UPDATE)
  40. private Date gmtModified;
  41. }

响应参数:

4.3 删除小节,删除对应阿里云视频

请求url:/eduservice/video/{id}
请求方式:post
请求参数:
响应参数:

5、课程信息

5.1 课程列表查询

请求url:/eduservice/course/{current}/{limit}
请求方式:post
请求参数:

  1. @Data
  2. public class CourseQuery {
  3. @ApiModelProperty(value = "课程标题,模糊查询")
  4. private String title;
  5. @ApiModelProperty(value = "课程状态 Draft未发布 Normal已发布")
  6. private String status;
  7. }

响应参数:

5.2 课程最终发布(修改课程状态)

请求url:/eduservice/course/publishCourse/{id}
请求方式:post
请求参数:
响应参数:

5.3 删除课程信息

请求url:/eduservice/course/{courseId}
请求方式:delete
请求参数:
响应参数:

四、Bander列表

五、订单管理

六、权限管理