package com.ningdatech.pmapi.workbench.controller;

import com.ningdatech.pmapi.workbench.manage.WorkbenchManage;
import com.ningdatech.pmapi.workbench.model.vo.WorkbenchVO;
import io.swagger.annotations.Api;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.*;

/**
 * 工作台前端控制器
 * @author ZPF
 * @since 2023/03/17 15:35
 */
@RestController
@AllArgsConstructor
@Api(tags = "工作台控制器")
@RequestMapping("/api/v1/workbench")
public class WorkbenchController {

    private WorkbenchManage workbenchManage;

    /**
     * @param year
     * @return
     */
    @GetMapping
    public WorkbenchVO workbench(@RequestParam(defaultValue = "2023") Integer year){
        return workbenchManage.getWorkbenchData(year);
    }

}
