From 5d8aedbe9bbdfc15c25f89eebf4552566e77baf4 Mon Sep 17 00:00:00 2001 From: cherishsince Date: Thu, 30 May 2024 10:26:23 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E8=A7=A3=E5=86=B3todo=E3=80=91image?= =?UTF-8?q?=20=E5=88=A0=E9=99=A4=E9=87=8D=E5=91=BD=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../module/ai/controller/admin/image/AiImageController.java | 6 +++--- .../yudao/module/ai/service/image/AiImageService.java | 2 +- .../yudao/module/ai/service/image/AiImageServiceImpl.java | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/controller/admin/image/AiImageController.java b/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/controller/admin/image/AiImageController.java index e9e35352e..dc7d80c2b 100644 --- a/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/controller/admin/image/AiImageController.java +++ b/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/controller/admin/image/AiImageController.java @@ -78,10 +78,10 @@ public class AiImageController { } @Operation(summary = "删除【我的】绘画记录") - @DeleteMapping("/my-delete") + @DeleteMapping("/delete-my") @Parameter(name = "id", required = true, description = "绘画编号", example = "1024") - public CommonResult myDelete(@RequestParam("id") Long id) { - return success(aiImageService.myDelete(id, getLoginUserId())); + public CommonResult deleteMyById(@RequestParam("id") Long id) { + return success(aiImageService.deleteMyById(id, getLoginUserId())); } } diff --git a/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageService.java b/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageService.java index 3d8c30d49..1569ce05d 100644 --- a/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageService.java +++ b/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageService.java @@ -62,6 +62,6 @@ public interface AiImageService { * @param id * @param loginUserId */ - Boolean myDelete(Long id, Long loginUserId); + Boolean deleteMyById(Long id, Long loginUserId); } diff --git a/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageServiceImpl.java b/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageServiceImpl.java index 6e0ede470..337d9fa4b 100644 --- a/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageServiceImpl.java +++ b/yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/service/image/AiImageServiceImpl.java @@ -184,7 +184,7 @@ public class AiImageServiceImpl implements AiImageService { } @Override - public Boolean myDelete(Long id, Long userId) { + public Boolean deleteMyById(Long id, Long userId) { // 校验是否存在,并获取 image AiImageDO image = validateExists(id); // 是否属于当前用户