fix: 优化商品单位不能为空

This commit is contained in:
misworga831 2023-09-19 17:12:28 +08:00
parent 7db7afad4a
commit 02dd37c87f

View File

@ -117,7 +117,7 @@ public class GoodsStoreController {
@ApiOperation(value = "修改商品") @ApiOperation(value = "修改商品")
@PutMapping(value = "/update/{goodsId}", consumes = "application/json", produces = "application/json") @PutMapping(value = "/update/{goodsId}", consumes = "application/json", produces = "application/json")
public ResultMessage<GoodsOperationDTO> update(@RequestBody GoodsOperationDTO goodsOperationDTO, @PathVariable String goodsId) { public ResultMessage<GoodsOperationDTO> update(@Valid @RequestBody GoodsOperationDTO goodsOperationDTO, @PathVariable String goodsId) {
goodsService.editGoods(goodsOperationDTO, goodsId); goodsService.editGoods(goodsOperationDTO, goodsId);
return ResultUtil.success(); return ResultUtil.success();
} }