|  |  |  | 
|---|
|  |  |  | @PreventRepeat | 
|---|
|  |  |  | @ApiOperation("新建") | 
|---|
|  |  |  | @PostMapping("/create") | 
|---|
|  |  |  | //    @RequiresPermissions("business:basegoods:create") | 
|---|
|  |  |  | @RequiresPermissions("business:basegoods:create") | 
|---|
|  |  |  | public ApiResponse create(@RequestBody BaseGoodsCreateOrUpdateRequest baseGoods) { | 
|---|
|  |  |  | return ApiResponse.success(baseGoodsService.create(baseGoods)); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @ApiOperation("根据ID查询") | 
|---|
|  |  |  | @GetMapping("/{id}") | 
|---|
|  |  |  | //    @RequiresPermissions("business:basegoods:query") | 
|---|
|  |  |  | public ApiResponse findById(@PathVariable Integer id) { | 
|---|
|  |  |  | return ApiResponse.success(baseGoodsService.findById(id)); | 
|---|
|  |  |  | @RequiresPermissions("business:basegoods:query") | 
|---|
|  |  |  | public ApiResponse<BaseGoodsDTO> findById(@PathVariable Integer id) { | 
|---|
|  |  |  | return ApiResponse.success(baseGoodsService.findByIdBaseGoods(id)); | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | /** | 
|---|
|  |  |  | 
|---|
|  |  |  | */ | 
|---|
|  |  |  | @ApiOperation("根据ID查询平台商品详细信息") | 
|---|
|  |  |  | @GetMapping("/findByIdBaseGoods") | 
|---|
|  |  |  | //    @RequiresPermissions("business:basegoods:query") | 
|---|
|  |  |  | @RequiresPermissions("business:basegoods:query") | 
|---|
|  |  |  | public ApiResponse<BaseGoodsDTO> findByIdBaseGoods(@RequestParam Integer id){ | 
|---|
|  |  |  | BaseGoodsDTO byIdBaseGoods = baseGoodsService.findByIdBaseGoods(id); | 
|---|
|  |  |  | return ApiResponse.success(byIdBaseGoods); | 
|---|
|  |  |  | 
|---|
|  |  |  | */ | 
|---|
|  |  |  | @ApiOperation("根据ID修改-编辑修改") | 
|---|
|  |  |  | @PostMapping("/update") | 
|---|
|  |  |  | //    @RequiresPermissions("business:basegoods:update") | 
|---|
|  |  |  | @RequiresPermissions("business:basegoods:update") | 
|---|
|  |  |  | public ApiResponse update(@RequestBody BaseGoodsCreateOrUpdateRequest baseGoods){ | 
|---|
|  |  |  | baseGoodsService.update(baseGoods); | 
|---|
|  |  |  | return ApiResponse.success(null); | 
|---|