package com.yuanchu.limslaboratory.controller; import com.yuanchu.limslaboratory.annotation.AuthHandler; import com.yuanchu.limslaboratory.pojo.vo.ProjectNumVo; import com.yuanchu.limslaboratory.service.WorkService; import com.yuanchu.limslaboratory.vo.Result; import io.swagger.annotations.Api; import io.swagger.annotations.ApiImplicitParam; import io.swagger.annotations.ApiImplicitParams; import io.swagger.annotations.ApiOperation; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import javax.annotation.Resource; @Api(tags = "智能图表-->工作统计") @RestController @RequestMapping("/work") public class WorkController { @Resource WorkService workService; @ApiOperation("责任人项目数统计") @ApiImplicitParams(value = { @ApiImplicitParam(name = "startTime", value = "检验开始日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "endTime", value = "检验结束日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "type", value = "检验类型(0:原材料;1:成品;2:委托品)", dataTypeClass = Integer.class, required = true) }) @GetMapping("/dutyMater") @AuthHandler public Result dutyMater(String startTime,String endTime,Integer type) { return Result.success(workService.dutyMater(startTime,endTime,type)); } @ApiOperation("执行人项目数统计") @ApiImplicitParams(value = { @ApiImplicitParam(name = "startTime", value = "检验开始日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "endTime", value = "检验结束日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "type", value = "检验类型(0:原材料;1:成品;2:委托品)", dataTypeClass = Integer.class, required = true) }) @GetMapping("/executeMater") @AuthHandler public Result executeMater(String startTime,String endTime,Integer type) { return Result.success(workService.executeMater(startTime,endTime,type)); } @ApiOperation("责任人及时率") @ApiImplicitParams(value = { @ApiImplicitParam(name = "startTime", value = "检验开始日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "endTime", value = "检验结束日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "type", value = "检验类型(0:原材料;1:成品;2:委托品)", dataTypeClass = Integer.class, required = true) }) @GetMapping("/dutytimely") @AuthHandler public Result dutytimely(String startTime,String endTime,Integer type) { return Result.success(workService.dutytimely(startTime,endTime,type)); } @ApiOperation("执行人及时率") @ApiImplicitParams(value = { @ApiImplicitParam(name = "startTime", value = "检验开始日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "endTime", value = "检验结束日期", dataTypeClass = String.class, required = true), @ApiImplicitParam(name = "type", value = "检验类型(0:原材料;1:成品;2:委托品)", dataTypeClass = Integer.class, required = true) }) @GetMapping("/executetimely") @AuthHandler public Result executetimely(String startTime,String endTime,Integer type) { return Result.success(workService.executetimely(startTime,endTime,type)); } }