提交 | 用户 | 时间
|
92d87e
|
1 |
package com.iailab.module.mcs.controller; |
潘 |
2 |
|
|
3 |
import com.iailab.framework.common.constant.Constant; |
|
4 |
import com.iailab.framework.common.page.PageData; |
|
5 |
import com.iailab.framework.common.pojo.CommonResult; |
|
6 |
import com.iailab.module.mcs.dto.StModelRequestLogDTO; |
|
7 |
import com.iailab.module.mcs.service.StModelRequestLogService; |
|
8 |
import io.swagger.v3.oas.annotations.tags.Tag; |
|
9 |
import io.swagger.v3.oas.annotations.Operation; |
|
10 |
import io.swagger.v3.oas.annotations.Parameter; |
|
11 |
import io.swagger.v3.oas.annotations.Parameters; |
|
12 |
import javax.annotation.Resource; |
|
13 |
import org.springframework.web.bind.annotation.GetMapping; |
|
14 |
import org.springframework.web.bind.annotation.RequestMapping; |
|
15 |
import org.springframework.web.bind.annotation.RequestParam; |
|
16 |
import org.springframework.web.bind.annotation.RestController; |
|
17 |
|
|
18 |
|
|
19 |
import java.util.Map; |
|
20 |
|
|
21 |
/** |
|
22 |
* @author PanZhibao |
|
23 |
* @Description |
|
24 |
* @createTime 2024年05月22日 |
|
25 |
*/ |
|
26 |
@RestController |
|
27 |
@RequestMapping("/model/mcs/model-request-log") |
|
28 |
@Tag(name = "模型调用日志表") |
|
29 |
public class StModelRequestLogController { |
|
30 |
|
|
31 |
@Resource |
|
32 |
private StModelRequestLogService stModelRequestLogService; |
|
33 |
|
|
34 |
@GetMapping("page") |
|
35 |
@Operation(summary = "分页") |
|
36 |
@Parameters({ |
|
37 |
@Parameter(name = Constant.PAGE, description = "当前页码,从1开始", required = true) , |
|
38 |
@Parameter(name = Constant.LIMIT, description = "每页显示记录数", required = true) , |
|
39 |
@Parameter(name = Constant.ORDER_FIELD, description = "排序字段") , |
|
40 |
@Parameter(name = Constant.ORDER, description = "排序方式,可选值(asc、desc)") |
|
41 |
}) |
|
42 |
public CommonResult<PageData<StModelRequestLogDTO>> page(@RequestParam Map<String, Object> params){ |
|
43 |
PageData<StModelRequestLogDTO> page = stModelRequestLogService.page(params); |
|
44 |
return new CommonResult<PageData<StModelRequestLogDTO>>().setData(page); |
|
45 |
} |
|
46 |
} |