package com.qmth.sop.server.api;

import com.qmth.boot.api.constant.ApiConstant;
import com.qmth.sop.business.bean.report.QualityAnalyseReportBean;
import com.qmth.sop.business.service.QualityAnalyseReportService;
import com.qmth.sop.common.contant.SystemConstant;
import com.qmth.sop.common.util.Result;
import com.qmth.sop.common.util.ResultUtil;
import io.swagger.annotations.*;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@Api(tags = "质量监控分析Controller")
@RestController
@RequestMapping(ApiConstant.DEFAULT_URI_PREFIX + SystemConstant.PREFIX_URL_QUALITY_ANALYSE)
public class QualityAnalyseReportController {

    @Resource
    QualityAnalyseReportService qualityAnalyseReportService;

    @ApiOperation(value = "大区质量问题统计")
    @RequestMapping(value = "/area_manager/report", method = RequestMethod.POST)
    @ApiResponses({ @ApiResponse(code = 200, message = "质量监控分析报表", response = QualityAnalyseReportBean.class) })
    public Result areaManagerReport(@ApiParam(value = "服务单元id", required = true) @RequestParam Long serviceId) {
        return ResultUtil.ok();
    }

    @ApiOperation(value = "人力商质量问题统计")
    @RequestMapping(value = "/human_supplier/report", method = RequestMethod.POST)
    @ApiResponses({ @ApiResponse(code = 200, message = "质量监控分析报表", response = QualityAnalyseReportBean.class) })
    public Result humanSupplierReport(@ApiParam(value = "服务单元id", required = true) @RequestParam Long serviceId) {
        return ResultUtil.ok();
    }

    @ApiOperation(value = "质量问题原因分类")
    @RequestMapping(value = "/type/report", method = RequestMethod.POST)
    @ApiResponses({ @ApiResponse(code = 200, message = "质量监控分析报表", response = QualityAnalyseReportBean.class) })
    public Result typeReport(@ApiParam(value = "服务单元id", required = true) @RequestParam Long serviceId) {
        return ResultUtil.ok();
    }
}
