| | |
| | | |
| | | @ApiOperation(value = "上报(更新检验状态)") |
| | | @ApiImplicitParams(value = { |
| | | @ApiImplicitParam(name = "id", value = "检验单id", dataTypeClass = Integer.class, required = true) |
| | | @ApiImplicitParam(name = "id", value = "检验单id", dataTypeClass = Integer.class, required = true), |
| | | @ApiImplicitParam(name = "number", value = "不合格数量", dataTypeClass = Integer.class) |
| | | }) |
| | | @PostMapping("/updateRawInspectsById/{id}") |
| | | public Result updateRawInspectsById(@PathVariable Integer id) { |
| | | public Result updateRawInspectsById(@PathVariable Integer id,Integer number) { |
| | | //如果已经上报了不能再一次上报 |
| | | RawInspect rawInspect = rawInspectService.getById(id); |
| | | if (rawInspect.getInsState() == 1) { |
| | | return Result.fail("已经上报过了,不能再次上报!"); |
| | | } |
| | | return Result.success(rawInspectService.updateRawInspectsById(id)); |
| | | return Result.success(rawInspectService.updateRawInspectsById(id,number)); |
| | | } |
| | | |
| | | } |