package com.dsk.web.controller.business;

import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.utils.SecurityUtils;
import com.dsk.system.domain.business.dto.BusinessSearchDto;
import com.dsk.system.service.IBusinessOverviewService;
import io.swagger.annotations.Api;
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;

/**
 * 项目概览
 * @author lcl
 * @create 2023/8/14
 */
@Api("项目概览")
@RestController
@RequestMapping("/business/overview")
public class BusinessOverviewController extends BaseController {

    @Autowired
    private IBusinessOverviewService baseService;

    /**
     * 项目统计
     */
    @GetMapping("/statistics")
    public AjaxResult statistics(){
        return AjaxResult.success(baseService.statistics(new BusinessSearchDto(SecurityUtils.getUserId())));
    }
}
