| | |
| | | }) |
| | | @PostMapping("/write") |
| | | public Result<?> write(Integer id, String required, String internal) { |
| | | Integer write = productService.write(id, required, internal); |
| | | if (write >= 1){ |
| | | return Result.success("更新成功"); |
| | | } |
| | | return Result.fail("更新失败"); |
| | | } |
| | | |
| | | @ApiOperation("添加同一个型号技术指标的版本") |
| | | @ApiImplicitParams(value = { |
| | | @ApiImplicitParam(name = "specificationsId", value = "型号id", dataTypeClass = Integer.class, required = true), |
| | | @ApiImplicitParam(name = "version", value = "当前版本", dataTypeClass = Integer.class, required = true) |
| | | }) |
| | | @PostMapping("/addVersion") |
| | | public Result<?> addVersion(Integer specificationsId ,Integer version) { |
| | | Integer version1 = productService.addVersion(specificationsId,version); |
| | | return Result.success("添加型号"+specificationsId+"的技术指标版本"+version1+"成功"); |
| | | return Result.success(productService.write(id, required, internal)); |
| | | } |
| | | |
| | | @ApiOperation(value = "删除") |