|
@@ -0,0 +1,55 @@
|
|
|
|
+package com.example.controller.user;
|
|
|
|
+
|
|
|
|
+import com.example.dto.PageQueryDTO;
|
|
|
|
+import com.example.result.PageResult;
|
|
|
|
+import com.example.result.Result;
|
|
|
|
+import com.example.service.OpenService;
|
|
|
|
+import io.swagger.annotations.Api;
|
|
|
|
+import io.swagger.annotations.ApiOperation;
|
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
|
+
|
|
|
|
+@RestController
|
|
|
|
+@Slf4j
|
|
|
|
+@Api(tags = "公开类相关接口")
|
|
|
|
+@RequestMapping("/open")
|
|
|
|
+public class OpenController {
|
|
|
|
+
|
|
|
|
+ @Autowired
|
|
|
|
+ private OpenService openService;
|
|
|
|
+
|
|
|
|
+ @GetMapping("/page")
|
|
|
|
+ @ApiOperation(value = "首页分页查询")
|
|
|
|
+ public Result<PageResult> page(PageQueryDTO pageQueryDTO) {
|
|
|
|
+ log.info("首页分页查询,查询参数:{}", pageQueryDTO);
|
|
|
|
+ PageResult pageResult = openService.page(pageQueryDTO);
|
|
|
|
+ return Result.success(pageResult);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @GetMapping("/awards/page")
|
|
|
|
+ @ApiOperation(value = "获奖分页查询")
|
|
|
|
+ public Result<PageResult> AwardsPage(PageQueryDTO pageQueryDTO) {
|
|
|
|
+ log.info("获奖分页查询,查询参数:{}", pageQueryDTO);
|
|
|
|
+ PageResult pageResult = openService.AwardsPage(pageQueryDTO);
|
|
|
|
+ return Result.success(pageResult);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @GetMapping("/work/page")
|
|
|
|
+ @ApiOperation(value = "著作分页查询")
|
|
|
|
+ public Result<PageResult> WorkPage(PageQueryDTO pageQueryDTO) {
|
|
|
|
+ log.info("著作分页查询,查询参数:{}", pageQueryDTO);
|
|
|
|
+ PageResult pageResult = openService.WorkPage(pageQueryDTO);
|
|
|
|
+ return Result.success(pageResult);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @GetMapping("/thesis/page")
|
|
|
|
+ @ApiOperation(value = "论文分页查询")
|
|
|
|
+ public Result<PageResult> ThesisPage(PageQueryDTO pageQueryDTO) {
|
|
|
|
+ log.info("论文分页查询,查询参数:{}", pageQueryDTO);
|
|
|
|
+ PageResult pageResult = openService.ThesisPage(pageQueryDTO);
|
|
|
|
+ return Result.success(pageResult);
|
|
|
|
+ }
|
|
|
|
+}
|