소스 검색

用户拥有题库商品

change 3 년 전
부모
커밋
1ed5cfe45b
1개의 변경된 파일57개의 추가작업 그리고 0개의 파일을 삭제
  1. 57 0
      zhongzheng-api/src/main/java/com/zhongzheng/controller/course/CourseHandoutsController.java

+ 57 - 0
zhongzheng-api/src/main/java/com/zhongzheng/controller/course/CourseHandoutsController.java

@@ -0,0 +1,57 @@
+package com.zhongzheng.controller.course;
+
+import com.zhongzheng.common.annotation.Log;
+import com.zhongzheng.common.core.controller.BaseController;
+import com.zhongzheng.common.core.domain.AjaxResult;
+import com.zhongzheng.common.core.page.TableDataInfo;
+import com.zhongzheng.common.enums.BusinessType;
+import com.zhongzheng.modules.course.bo.CourseHandoutsAddBo;
+import com.zhongzheng.modules.course.bo.CourseHandoutsEditBo;
+import com.zhongzheng.modules.course.bo.CourseHandoutsQueryBo;
+import com.zhongzheng.modules.course.service.ICourseHandoutsService;
+import com.zhongzheng.modules.course.vo.CourseHandoutsVo;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import lombok.RequiredArgsConstructor;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+/**
+ * 讲义列Controller
+ * 
+ * @author ruoyi
+ * @date 2021-11-02
+ */
+@Api(value = "讲义列控制器", tags = {"讲义列管理"})
+@RequiredArgsConstructor(onConstructor_ = @Autowired)
+@RestController
+@RequestMapping("/course/handouts")
+public class CourseHandoutsController extends BaseController {
+
+    private final ICourseHandoutsService iCourseHandoutsService;
+
+    /**
+     * 查询讲义列列表
+     */
+    @ApiOperation("查询讲义列列表")
+    @GetMapping("/list")
+    public TableDataInfo<CourseHandoutsVo> list(CourseHandoutsQueryBo bo) {
+        startPage();
+        List<CourseHandoutsVo> list = iCourseHandoutsService.queryList(bo);
+        return getDataTable(list);
+    }
+
+
+
+    /**
+     * 获取讲义列详细信息
+     */
+    @ApiOperation("获取讲义列详细信息")
+    @GetMapping("/{handoutsId}")
+    public AjaxResult<CourseHandoutsVo> getInfo(@PathVariable("handoutsId" ) Long handoutsId) {
+        return AjaxResult.success(iCourseHandoutsService.queryById(handoutsId));
+    }
+}