mall icon indicating copy to clipboard operation
mall copied to clipboard

Update the @RequestMappings with particular @GetMappings @PostMappings @PutMappings @DeleteMapping.

Open YogenderSha opened this issue 1 year ago • 3 comments

In the Java controllers the @RequestMappings are to be replaced with @GetMapping @PostMappings @PutMappings @DeleteMapping to make code more readable and short .

@ApiOperation("编辑活动") @RequestMapping(value = "/update/{id}", method = RequestMethod.POST) @ResponseBody public CommonResult update(@PathVariable Long id, @RequestBody SmsFlashPromotion flashPromotion) { int count = flashPromotionService.update(id, flashPromotion); if (count > 0) { return CommonResult.success(count); } return CommonResult.failed(); }

Here the @RequestMapping(value = "/update/{id}", method = RequestMethod.POST) can be updated with @PutMapping("/update/{id}") simply .

YogenderSha avatar Jun 16 '23 05:06 YogenderSha

I want to work on this issue.

YogenderSha avatar Jun 27 '23 15:06 YogenderSha

Hey any update on this issue ?

YogenderSha avatar Jul 05 '23 12:07 YogenderSha

Opened the Pull Request #614. Please review it there.

YogenderSha avatar Jul 05 '23 12:07 YogenderSha