feat(后台管理): 完善代码

master
wayn 4 years ago
parent 64d47eaca9
commit 64eb0ae501

@ -35,6 +35,8 @@ public class BannerController extends BaseController {
@PutMapping
public R updateChannel(@Validated @RequestBody ShopBanner banner) {
banner.setUpdateBy(SecurityUtils.getUsername());
banner.setUpdateTime(new Date());
return R.result(iBannerService.updateById(banner));
}
@ -45,6 +47,6 @@ public class BannerController extends BaseController {
@DeleteMapping("{bannerId}")
public R deleteChannel(@PathVariable Long bannerId) {
return R.success().add("data", iBannerService.removeById(bannerId));
return R.result(iBannerService.removeById(bannerId));
}
}

@ -55,6 +55,6 @@ public class ChannelController extends BaseController {
@DeleteMapping("{channelId}")
public R deleteChannel(@PathVariable Long channelId) {
return R.success().add("data", iChannelService.removeById(channelId));
return R.result(iChannelService.removeById(channelId));
}
}

Loading…
Cancel
Save