Commit 41071fc68905e5de609512359403d8ae8a80ba21
1 parent
39de7444
【代码优化】AI:对话 deleteChatConversationMyByUnpinned 接口
Showing
3 changed files
with
4 additions
and
13 deletions
yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/controller/admin/chat/AiChatConversationController.java
| @@ -23,7 +23,6 @@ import org.springframework.web.bind.annotation.*; | @@ -23,7 +23,6 @@ import org.springframework.web.bind.annotation.*; | ||
| 23 | 23 | ||
| 24 | import java.util.List; | 24 | import java.util.List; |
| 25 | import java.util.Map; | 25 | import java.util.Map; |
| 26 | -import java.util.function.Consumer; | ||
| 27 | 26 | ||
| 28 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; | 27 | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| 29 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; | 28 | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList; |
| @@ -79,9 +78,8 @@ public class AiChatConversationController { | @@ -79,9 +78,8 @@ public class AiChatConversationController { | ||
| 79 | return success(true); | 78 | return success(true); |
| 80 | } | 79 | } |
| 81 | 80 | ||
| 82 | - // TODO 芋艿:这个 url 可以改下 | ||
| 83 | - @DeleteMapping("/delete-my-all-except-pinned") | ||
| 84 | - @Operation(summary = "删除所有对话(置顶除外)") | 81 | + @DeleteMapping("/delete-by-unpinned") |
| 82 | + @Operation(summary = "删除未置顶的聊天对话") | ||
| 85 | public CommonResult<Boolean> deleteChatConversationMyByUnpinned() { | 83 | public CommonResult<Boolean> deleteChatConversationMyByUnpinned() { |
| 86 | chatConversationService.deleteChatConversationMyByUnpinned(getLoginUserId()); | 84 | chatConversationService.deleteChatConversationMyByUnpinned(getLoginUserId()); |
| 87 | return success(true); | 85 | return success(true); |
yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/controller/admin/image/AiImageController.http
| 1 | - | ||
| 2 | ### 生成图片:OpenAI(DALL) | 1 | ### 生成图片:OpenAI(DALL) |
| 3 | POST {{baseUrl}}/ai/image/draw | 2 | POST {{baseUrl}}/ai/image/draw |
| 4 | Content-Type: application/json | 3 | Content-Type: application/json |
| @@ -29,8 +28,7 @@ Authorization: {{token}} | @@ -29,8 +28,7 @@ Authorization: {{token}} | ||
| 29 | "style": "vivid" | 28 | "style": "vivid" |
| 30 | } | 29 | } |
| 31 | 30 | ||
| 32 | -### 生成图片:生成图片 | ||
| 33 | - | 31 | +### 生成图片:生成图片(Midjourney) |
| 34 | POST {{baseUrl}}/ai/image/midjourney/imagine | 32 | POST {{baseUrl}}/ai/image/midjourney/imagine |
| 35 | Content-Type: application/json | 33 | Content-Type: application/json |
| 36 | Authorization: {{token}} | 34 | Authorization: {{token}} |
| @@ -40,6 +38,5 @@ Authorization: {{token}} | @@ -40,6 +38,5 @@ Authorization: {{token}} | ||
| 40 | "model": "midjourney", | 38 | "model": "midjourney", |
| 41 | "width": "1", | 39 | "width": "1", |
| 42 | "height": "1", | 40 | "height": "1", |
| 43 | - "version": "6.0", | ||
| 44 | - "base64Array": [] | 41 | + "version": "6.0" |
| 45 | } | 42 | } |
| 46 | \ No newline at end of file | 43 | \ No newline at end of file |
yudao-module-ai/yudao-module-ai-biz/src/main/java/cn/iocoder/yudao/module/ai/controller/admin/music/AiMusicController.java
| @@ -38,10 +38,6 @@ public class AiMusicController { | @@ -38,10 +38,6 @@ public class AiMusicController { | ||
| 38 | @PostMapping("/generate") | 38 | @PostMapping("/generate") |
| 39 | @Operation(summary = "音乐生成") | 39 | @Operation(summary = "音乐生成") |
| 40 | public CommonResult<List<Long>> generateMusic(@RequestBody @Valid AiSunoGenerateReqVO reqVO) { | 40 | public CommonResult<List<Long>> generateMusic(@RequestBody @Valid AiSunoGenerateReqVO reqVO) { |
| 41 | -// if (true) { | ||
| 42 | -// musicService.syncMusic(); | ||
| 43 | -// return null; | ||
| 44 | -// } | ||
| 45 | return success(musicService.generateMusic(getLoginUserId(), reqVO)); | 41 | return success(musicService.generateMusic(getLoginUserId(), reqVO)); |
| 46 | } | 42 | } |
| 47 | 43 |