guoyuji
2024-03-22 73be6b08f5a94e71550fe788c5d74705daa91be0
north-glass-erp/src/main/java/com/example/erp/controller/pp/ReportingWorkController.java
@@ -24,7 +24,7 @@
        this.reportingWorkService = reportingWorkService;
    }
    @ApiOperation("报工新增查询")
    @PostMapping  ("/addSelectLastWork/{processIdStr}/{technologyStr}/{process}")
    public Result AddSelectLastWork(
            @PathVariable String processIdStr,
@@ -32,6 +32,7 @@
            @PathVariable String process)  {
        return  Result.seccess(reportingWorkService.AddSelectLastWorkSv(processIdStr,technologyStr,process));
    }
    @ApiOperation("查询工序")
    @PostMapping  ("/selectProcess")
    public Result SelectProcess()  {
        return  Result.seccess(reportingWorkService.SelectProcessSv());
@@ -55,9 +56,9 @@
        return  Result.seccess(reportingWorkService.selectUpdateReportingWorkSv(reportingWorkId));
    }
    @ApiOperation("报工修改")
    @PostMapping  ("/updateReportingWork")
    public Result updateReportingWork(@RequestBody Map<String,Object> reportingWork)  {
        return  Result.seccess(reportingWorkService.updateReportingWork(reportingWork));
    @PostMapping  ("/updateReportingWork/{reviewState}")
    public Result updateReportingWork(@PathVariable String reviewState,@RequestBody Map<String,Object> reportingWork)  {
        return  Result.seccess(reportingWorkService.updateReportingWork(reportingWork,reviewState));
    }
    @ApiOperation("报工查询接口")
@@ -83,4 +84,40 @@
        }
    }
    @ApiOperation("质检审核查询接口")
    @PostMapping  ("/selectQualityTesting/{pageNum}/{pageSize}/{selectTime1}/{selectTime2}/{state}/{processId}")
    public Result selectQualityTesting(
            @PathVariable Integer pageNum,
            @PathVariable Integer pageSize,
            @PathVariable Date selectTime1,
            @PathVariable Date selectTime2,
            @PathVariable Integer state,
            @PathVariable String processId,
            @RequestBody ReportingWork reportingWork){
        return Result.seccess(reportingWorkService.selectQualityTestingSv(pageNum,pageSize,selectTime1,selectTime2,state,processId,reportingWork));
    }
    @ApiOperation("质检审核审核")
    @PostMapping  ("/updateQualityStatus/{reportingWorkId}/{username}")
    public Result updateQualityStatus(@PathVariable String reportingWorkId,@PathVariable String username)  {
        if(reportingWorkService.updateQualityStatusSv(reportingWorkId,username)){
            return Result.seccess();
        }else {
            throw new ServiceException(Constants.Code_500,"审核失败");
        }
    }
    @ApiOperation("质检审核明细查询接口")
    @PostMapping  ("/detailsQuality/{reportingWorkId}/{processId}/{thisProcess}")
    public Result detailsQuality(
            @PathVariable String reportingWorkId,
            @PathVariable String processId,
            @PathVariable String thisProcess,
            @RequestBody ReportingWork reportingWork){
        return Result.seccess(reportingWorkService.detailsQualitySv(reportingWorkId,processId,thisProcess,reportingWork));
    }
}