SubjectController.java 1.1 KB

123456789101112131415161718192021222324252627282930
  1. package com.keao.edu.controller;
  2. import com.keao.edu.common.controller.BaseController;
  3. import com.keao.edu.common.entity.HttpResponseResult;
  4. import com.keao.edu.common.page.PageInfo;
  5. import com.keao.edu.user.entity.Subject;
  6. import com.keao.edu.user.page.SubjectQueryInfo;
  7. import com.keao.edu.user.service.SubjectService;
  8. import io.swagger.annotations.Api;
  9. import io.swagger.annotations.ApiOperation;
  10. import org.springframework.beans.factory.annotation.Autowired;
  11. import org.springframework.web.bind.annotation.GetMapping;
  12. import org.springframework.web.bind.annotation.RequestMapping;
  13. import org.springframework.web.bind.annotation.RestController;
  14. @RequestMapping("subject")
  15. @Api(tags = "科目服务")
  16. @RestController
  17. public class SubjectController extends BaseController {
  18. @Autowired
  19. private SubjectService subjectService;
  20. @ApiOperation(value = "学生端分页查询科目列表")
  21. @GetMapping("/studentQueryPage")
  22. public HttpResponseResult<PageInfo<Subject>> studentQueryPage(SubjectQueryInfo queryInfo){
  23. return succeed(subjectService.queryPage(queryInfo));
  24. }
  25. }