| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102 |
- package nju.seec.helper.service;
- import nju.seec.helper.dto.ChooseDTO;
- import nju.seec.helper.dto.CourseDTO;
- import nju.seec.helper.dto.LoginUser;
- import nju.seec.helper.dto.ModifyCourseDTO;
- import nju.seec.helper.vo.CourseVO;
- import org.springframework.data.domain.Page;
- import org.springframework.data.domain.Pageable;
- /**
- * @author cst
- */
- public interface CourseService {
- /**
- * 创建课程
- *
- * @param teacher
- * @param courseDTO
- * @return
- */
- CourseVO createCourse(LoginUser teacher, CourseDTO courseDTO);
- /**
- * 修改课程
- *
- * @param user
- * @param modifyCourseDTO
- * @return
- */
- CourseVO modifyCourse(LoginUser user, ModifyCourseDTO modifyCourseDTO);
- /**
- * 删除课程(伪删除)
- *
- * @param user
- * @param courseId
- */
- void removeCourse(LoginUser user, Integer courseId);
- /**
- * 学生选课
- *
- * @param student
- * @param chooseDTO
- */
- void chooseCourse(LoginUser student, ChooseDTO chooseDTO);
- /**
- * 退课
- *
- * @param user
- * @param courseId
- */
- void quitCourse(LoginUser user, Integer courseId);
- /**
- * 获取课程
- *
- * @param key
- * @param pageable
- * @return
- */
- Page<CourseVO> getCourses(String key, Pageable pageable);
- /**
- * 教师获取创建课程
- *
- * @param teacher
- * @param key
- * @param pageable
- * @return
- */
- Page<CourseVO> teacherGetCourses(LoginUser teacher, String key, Pageable pageable);
- /**
- * 学生获取已选课程
- *
- * @param student
- * @param key
- * @param pageable
- * @return
- */
- Page<CourseVO> studentGetCourses(LoginUser student, String key, Pageable pageable);
- /**
- * 获取课程选课码
- *
- * @param user
- * @param courseId
- * @return
- */
- String getCourseCode(LoginUser user, Integer courseId);
- /**
- * 取得某课程
- *
- * @param courseId
- * @return
- */
- CourseVO getOneCourse(Integer courseId);
- }
|