feat: 新增任务下拉选项接口
This commit is contained in:
@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.google.protobuf.ServiceException;
|
||||
import com.guo.learningprogresstracker.common.Ops;
|
||||
import com.guo.learningprogresstracker.dto.TaskInfo;
|
||||
import com.guo.learningprogresstracker.dto.TaskOption;
|
||||
import com.guo.learningprogresstracker.dto.request.CreateTaskApplicationRequest;
|
||||
import com.guo.learningprogresstracker.dto.response.StudySessionResponse;
|
||||
import com.guo.learningprogresstracker.dto.response.TaskInfoResponse;
|
||||
@@ -128,6 +129,12 @@ public class TaskController {
|
||||
return CommonResult.success();
|
||||
}
|
||||
|
||||
@GetMapping("/options")
|
||||
@Operation(summary = "全部任务的最小选项(归类下拉用)")
|
||||
public CommonResult<List<TaskOption>> taskOptions() {
|
||||
return CommonResult.success(tasksService.taskOptions());
|
||||
}
|
||||
|
||||
@GetMapping
|
||||
@Operation(summary = "获取所有任务列表")
|
||||
public CommonResult<Page<TaskInfo>> tasksList(@RequestParam(value = "pageNum", defaultValue = "1") Integer pageNum,
|
||||
|
||||
Reference in New Issue
Block a user