diff --git a/package.json b/package.json index c8dab2b8..18be2c2e 100644 --- a/package.json +++ b/package.json @@ -47,7 +47,7 @@ "driver.js": "^1.3.1", "echarts": "^5.5.0", "echarts-wordcloud": "^2.1.0", - "element-plus": "2.6.1", + "element-plus": "2.7.0", "fast-xml-parser": "^4.3.2", "highlight.js": "^11.9.0", "jsencrypt": "^3.3.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 0c2351e0..55dceb8d 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -17,6 +17,9 @@ dependencies: '@iconify/iconify': specifier: ^3.1.1 version: 3.1.1 + '@microsoft/fetch-event-source': + specifier: ^2.0.1 + version: 2.0.1 '@videojs-player/vue': specifier: ^1.0.0 version: 1.0.0(@types/video.js@7.3.58)(video.js@7.21.5)(vue@3.4.21) @@ -69,8 +72,8 @@ dependencies: specifier: ^2.1.0 version: 2.1.0(echarts@5.5.0) element-plus: - specifier: 2.6.1 - version: 2.6.1(vue@3.4.21) + specifier: 2.7.0 + version: 2.7.0(vue@3.4.21) fast-xml-parser: specifier: ^4.3.2 version: 4.3.6 @@ -83,6 +86,9 @@ dependencies: lodash-es: specifier: ^4.17.21 version: 4.17.21 + marked: + specifier: ^12.0.2 + version: 12.0.2 min-dash: specifier: ^4.1.1 version: 4.2.1 @@ -2360,6 +2366,10 @@ packages: '@jridgewell/sourcemap-codec': 1.4.15 dev: true + /@microsoft/fetch-event-source@2.0.1: + resolution: {integrity: sha512-W6CLUJ2eBMw3Rec70qrsEW0jOm/3twwJv21mrmj2yORiaVmVYGS4sSS5yUwvQc1ZlDLYGPnClVWmUUMagKNsfA==, tarball: https://registry.npmmirror.com/@microsoft/fetch-event-source/-/fetch-event-source-2.0.1.tgz} + dev: false + /@nodelib/fs.scandir@2.1.5: resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==, tarball: https://registry.npmmirror.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz} engines: {node: '>= 8'} @@ -5082,8 +5092,8 @@ packages: resolution: {integrity: sha512-9ItEpeu15hW5m8jKdriL+BQrgwDTXEL9pn4SkillWFu73ZNNNQ2BKKLS+ZHv2vC9UkNhosAeyfxOf/5OSeTCPA==, tarball: https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.4.750.tgz} dev: true - /element-plus@2.6.1(vue@3.4.21): - resolution: {integrity: sha512-6VRpLjwtIVdtUuITJPPKtpOH1NM6nuAkRE3q5O4Lrx0N1bYMhTkiqb2Jy7zfQuDPbOIkkF2OABTzegpNnzgsnQ==, tarball: https://registry.npmmirror.com/element-plus/-/element-plus-2.6.1.tgz} + /element-plus@2.7.0(vue@3.4.21): + resolution: {integrity: sha512-WAiaFLavuWFxof9qwkC27jvkh9nRcNnB506g1vvJSiVaVqjCBWUFCIyJKeN11M1qcv2cS5VV5PfSLjTIkrw87A==, tarball: https://registry.npmmirror.com/element-plus/-/element-plus-2.7.0.tgz} peerDependencies: vue: ^3.2.0 dependencies: @@ -6917,6 +6927,12 @@ packages: object-visit: 1.0.1 dev: true + /marked@12.0.2: + resolution: {integrity: sha512-qXUm7e/YKFoqFPYPa3Ukg9xlI5cyAtGmyEIzMfW//m6kXwCy2Ps9DYf5ioijFKQ8qyuscrHoY04iJGctu2Kg0Q==, tarball: https://registry.npmmirror.com/marked/-/marked-12.0.2.tgz} + engines: {node: '>= 18'} + hasBin: true + dev: false + /matches-selector@1.2.0: resolution: {integrity: sha512-c4vLwYWyl+Ji+U43eU/G5FwxWd4ZH0ePUsFs5y0uwD9HUEFBXUQ1zUUan+78IpRD+y4pUfG0nAzNM292K7ItvA==, tarball: https://registry.npmmirror.com/matches-selector/-/matches-selector-1.2.0.tgz} dev: true diff --git a/src/App.vue b/src/App.vue index 7407d97a..1f5f36d7 100644 --- a/src/App.vue +++ b/src/App.vue @@ -54,4 +54,8 @@ body { .#{$prefix-cls}-grey-mode { filter: grayscale(100%); } + +.scrollbar__view { + height: 99%!important; +} diff --git a/src/api/ai/chat/conversation/index.ts b/src/api/ai/chat/conversation/index.ts index 683646ea..08ad26a1 100644 --- a/src/api/ai/chat/conversation/index.ts +++ b/src/api/ai/chat/conversation/index.ts @@ -1,10 +1,10 @@ import request from '@/config/axios' -// AI 聊天会话 VO +// AI 聊天对话 VO export interface ChatConversationVO { - id: number // ID 编号 + id: string // ID 编号 userId: number // 用户编号 - title: string // 会话标题 + title: string // 对话标题 pinned: boolean // 是否置顶 roleId: number // 角色编号 modelId: number // 模型编号 @@ -12,33 +12,33 @@ export interface ChatConversationVO { temperature: number // 温度参数 maxTokens: number // 单条回复的最大 Token 数量 maxContexts: number // 上下文的最大 Message 数量 - updateTime: number // 更新时间 // 额外字段 + systemMessage?: string // 角色设定 modelName?: string // 模型名字 roleAvatar?: string // 角色头像 modelMaxTokens?: string // 模型的单条回复的最大 Token 数量 modelMaxContexts?: string // 模型的上下文的最大 Message 数量 } -// AI 聊天会话 API +// AI 聊天对话 API export const ChatConversationApi = { - // 获得【我的】聊天会话 - getChatConversationMy: async (id: number) => { + // 获得【我的】聊天对话 + getChatConversationMy: async (id: string) => { return await request.get({ url: `/ai/chat/conversation/get-my?id=${id}` }) }, - // 新增【我的】聊天会话 + // 新增【我的】聊天对话 createChatConversationMy: async (data?: ChatConversationVO) => { return await request.post({ url: `/ai/chat/conversation/create-my`, data }) }, - // 更新【我的】聊天会话 + // 更新【我的】聊天对话 updateChatConversationMy: async (data: ChatConversationVO) => { return await request.put({ url: `/ai/chat/conversation/update-my`, data }) }, - // 删除【我的】聊天会话 - deleteChatConversationMy: async (id: number) => { + // 删除【我的】聊天对话 + deleteChatConversationMy: async (id: string) => { return await request.delete({ url: `/ai/chat/conversation/delete-my?id=${id}` }) }, @@ -47,8 +47,18 @@ export const ChatConversationApi = { return await request.delete({ url: `/ai/chat/conversation/delete-my-all-except-pinned` }) }, - // 获得【我的】聊天会话列表 + // 获得【我的】聊天对话列表 getChatConversationMyList: async () => { return await request.get({ url: `/ai/chat/conversation/my-list` }) + }, + + // 获得对话分页 + getChatConversationPage: async (params: any) => { + return await request.get({ url: `/ai/chat/conversation/page`, params }) + }, + + // 管理员删除消息 + deleteChatConversationByAdmin: async (id: number) => { + return await request.delete({ url: `/ai/chat/conversation/delete-by-admin?id=${id}` }) } } diff --git a/src/api/ai/chat/message/index.ts b/src/api/ai/chat/message/index.ts index 05b4d804..f9e807a1 100644 --- a/src/api/ai/chat/message/index.ts +++ b/src/api/ai/chat/message/index.ts @@ -6,7 +6,7 @@ import { config } from '@/config/axios/config' // 聊天VO export interface ChatMessageVO { id: number // 编号 - conversationId: number // 会话编号 + conversationId: number // 对话编号 type: string // 消息类型 userId: string // 用户编号 roleId: string // 角色编号 @@ -15,17 +15,19 @@ export interface ChatMessageVO { content: string // 聊天内容 tokens: number // 消耗 Token 数量 createTime: Date // 创建时间 + roleAvatar: string // 角色头像 + userAvatar: string // 创建时间 } export interface ChatMessageSendVO { - conversationId: string // 会话编号 + conversationId: string // 对话编号 content: number // 聊天内容 } // AI chat 聊天 export const ChatMessageApi = { // 消息列表 - messageList: async (conversationId: number | null) => { + messageList: async (conversationId: string | null) => { return await request.get({ url: `/ai/chat/message/list-by-conversation-id?conversationId=${conversationId}` }) @@ -37,6 +39,7 @@ export const ChatMessageApi = { conversationId: number, content: string, ctrl, + enableContext: boolean, onMessage, onError, onClose @@ -51,7 +54,8 @@ export const ChatMessageApi = { openWhenHidden: true, body: JSON.stringify({ conversationId, - content + content, + useContext: enableContext }), onmessage: onMessage, onerror: onError, @@ -60,8 +64,25 @@ export const ChatMessageApi = { }) }, - // 发送 send 消息 + // 删除消息 delete: async (id: string) => { return await request.delete({ url: `/ai/chat/message/delete?id=${id}` }) + }, + + // 删除消息 - 对话所有消息 + deleteByConversationId: async (conversationId: string) => { + return await request.delete({ + url: `/ai/chat/message/delete-by-conversation-id?conversationId=${conversationId}` + }) + }, + + // 获得消息分页 + getChatMessagePage: async (params: any) => { + return await request.get({ url: '/ai/chat/message/page', params }) + }, + + // 管理员删除消息 + deleteChatMessageByAdmin: async (id: number) => { + return await request.delete({ url: `/ai/chat/message/delete-by-admin?id=${id}` }) } } diff --git a/src/api/ai/image/index.ts b/src/api/ai/image/index.ts new file mode 100644 index 00000000..7c7130e8 --- /dev/null +++ b/src/api/ai/image/index.ts @@ -0,0 +1,107 @@ +import request from '@/config/axios' + +// AI 绘图 VO +export interface ImageVO { + id: number // 编号 + platform: string // 平台 + model: string // 模型 + prompt: string // 提示词 + width: number // 图片宽度 + height: number // 图片高度 + status: number // 状态 + publicStatus: boolean // 公开状态 + picUrl: string // 任务地址 + errorMessage: string // 错误信息 + options: object // 配置 Map + taskId: number // 任务编号 + buttons: ImageMjButtonsVO[] // mj 操作按钮 + createTime: string // 创建时间 +} + +export interface ImagePageReqVO { + pageNo: number // 分页编号 + pageSize: number // 分页大小 +} + +export interface ImageDrawReqVO { + platform: string // 平台 + prompt: string // 提示词 + model: string // 模型 + style: string // 图像生成的风格 + width: string // 图片宽度 + height: string // 图片高度 + options: object // 绘制参数,Map +} + +export interface ImageMidjourneyImagineReqVO { + prompt: string // 提示词 + model: string // 模型 mj nijj + base64Array: string[] // size不能为空 + width: string // 图片宽度 + height: string // 图片高度 + version: string // 版本 +} + +export interface ImageMjActionVO { + id: number // 图片编号 + customId: string // MJ::JOB::upsample::1::85a4b4c1-8835-46c5-a15c-aea34fad1862 动作标识 +} + +export interface ImageMjButtonsVO { + customId: string // MJ::JOB::upsample::1::85a4b4c1-8835-46c5-a15c-aea34fad1862 动作标识 + emoji: string // 图标 emoji + label: string // Make Variations 文本 + style: number // 样式: 2(Primary)、3(Green) +} + +// AI API 密钥 API +export const ImageApi = { + // 获取【我的】绘图分页 + getImagePageMy: async (params: ImagePageReqVO) => { + return await request.get({ url: `/ai/image/my-page`, params }) + }, + // 获取【我的】绘图记录 + getImageMy: async (id: number) => { + return await request.get({ url: `/ai/image/get-my?id=${id}` }) + }, + // 获取【我的】绘图记录列表 + getImageListMyByIds: async (ids: number[]) => { + return await request.get({ url: `/ai/image/my-list-by-ids`, params: { ids: ids.join(',') } }) + }, + // 生成图片 + drawImage: async (data: ImageDrawReqVO) => { + return await request.post({ url: `/ai/image/draw`, data }) + }, + // 删除【我的】绘画记录 + deleteImageMy: async (id: number) => { + return await request.delete({ url: `/ai/image/delete-my?id=${id}` }) + }, + + // ================ midjourney 专属 ================ + + // 【Midjourney】生成图片 + midjourneyImagine: async (data: ImageMidjourneyImagineReqVO) => { + return await request.post({ url: `/ai/image/midjourney/imagine`, data }) + }, + // 【Midjourney】Action 操作(二次生成图片) + midjourneyAction: async (data: ImageMjActionVO) => { + return await request.post({ url: `/ai/image/midjourney/action`, data }) + }, + + // ================ 绘图管理 ================ + + // 查询绘画分页 + getImagePage: async (params: any) => { + return await request.get({ url: `/ai/image/page`, params }) + }, + + // 更新绘画发布状态 + updateImage: async (data: any) => { + return await request.put({ url: '/ai/image/update-public-status', data }) + }, + + // 删除绘画 + deleteImage: async (id: number) => { + return await request.delete({ url: `/ai/image/delete?id=` + id }) + } +} diff --git a/src/api/ai/music/index.ts b/src/api/ai/music/index.ts new file mode 100644 index 00000000..74b85268 --- /dev/null +++ b/src/api/ai/music/index.ts @@ -0,0 +1,41 @@ +import request from '@/config/axios' + +// AI 音乐 VO +export interface MusicVO { + id: number // 编号 + userId: number // 用户编号 + title: string // 音乐名称 + lyric: string // 歌词 + imageUrl: string // 图片地址 + audioUrl: string // 音频地址 + videoUrl: string // 视频地址 + status: number // 音乐状态 + gptDescriptionPrompt: string // 描述词 + prompt: string // 提示词 + platform: string // 模型平台 + model: string // 模型 + generateMode: number // 生成模式 + tags: string // 音乐风格标签 + duration: number // 音乐时长 + publicStatus: boolean // 是否发布 + taskId: string // 任务id + errorMessage: string // 错误信息 +} + +// AI 音乐 API +export const MusicApi = { + // 查询音乐分页 + getMusicPage: async (params: any) => { + return await request.get({ url: `/ai/music/page`, params }) + }, + + // 更新音乐 + updateMusic: async (data: any) => { + return await request.put({ url: '/ai/music/update', data }) + }, + + // 删除音乐 + deleteMusic: async (id: number) => { + return await request.delete({ url: `/ai/music/delete?id=` + id }) + } +} diff --git a/src/assets/ai/clear.svg b/src/assets/ai/clear.svg new file mode 100644 index 00000000..e75a4e8a --- /dev/null +++ b/src/assets/ai/clear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/assets/ai/gpt.svg b/src/assets/ai/gpt.svg new file mode 100644 index 00000000..603e2e95 --- /dev/null +++ b/src/assets/ai/gpt.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/components/ContentWrap/src/ContentWrap.vue b/src/components/ContentWrap/src/ContentWrap.vue index 454e95c9..c75e4b71 100644 --- a/src/components/ContentWrap/src/ContentWrap.vue +++ b/src/components/ContentWrap/src/ContentWrap.vue @@ -10,12 +10,13 @@ const prefixCls = getPrefixCls('content-wrap') defineProps({ title: propTypes.string.def(''), - message: propTypes.string.def('') + message: propTypes.string.def(''), + bodyStyle: propTypes.object.def({ padding: '20px' }) }) diff --git a/src/components/Icon/src/Icon.vue b/src/components/Icon/src/Icon.vue index 4246539f..a90bb37e 100644 --- a/src/components/Icon/src/Icon.vue +++ b/src/components/Icon/src/Icon.vue @@ -22,7 +22,7 @@ const props = defineProps({ const elRef = ref(null) -const isLocal = computed(() => props.icon.startsWith('svg-icon:')) +const isLocal = computed(() => props.icon?.startsWith('svg-icon:')) const symbolId = computed(() => { return unref(isLocal) ? `#icon-${props.icon.split('svg-icon:')[1]}` : props.icon diff --git a/src/components/MarkdownView/index.vue b/src/components/MarkdownView/index.vue index 6ecb2ea5..bf9ddd60 100644 --- a/src/components/MarkdownView/index.vue +++ b/src/components/MarkdownView/index.vue @@ -1,23 +1,33 @@ - diff --git a/src/layout/components/AppView.vue b/src/layout/components/AppView.vue index 44341873..88d5f0cc 100644 --- a/src/layout/components/AppView.vue +++ b/src/layout/components/AppView.vue @@ -38,24 +38,24 @@ provide('reload', reload) :class="[ 'p-[var(--app-content-padding)] w-[calc(100%-var(--app-content-padding)-var(--app-content-padding))] bg-[var(--app-content-bg-color)] dark:bg-[var(--el-bg-color)]', { - '!min-h-[calc(100%-var(--app-content-padding)-var(--app-content-padding)-var(--app-footer-height))]': + '!h-[calc(100%-var(--app-content-padding)-var(--app-content-padding)-var(--app-footer-height))]': (fixedHeader && (layout === 'classic' || layout === 'topLeft' || layout === 'top') && footer) || (!tagsView && layout === 'top' && footer), - '!min-h-[calc(100%-var(--app-content-padding)-var(--app-content-padding)-var(--app-footer-height)-var(--tags-view-height))]': + '!h-[calc(100%-var(--app-content-padding)-var(--app-content-padding)-var(--app-footer-height)-var(--tags-view-height))]': tagsView && layout === 'top' && footer, - '!min-h-[calc(100%-var(--tags-view-height)-var(--app-content-padding)-var(--app-content-padding)-var(--top-tool-height)-var(--app-footer-height))]': + '!h-[calc(100%-var(--tags-view-height)-var(--app-content-padding)-var(--app-content-padding)-var(--top-tool-height)-var(--app-footer-height))]': !fixedHeader && layout === 'classic' && footer, - '!min-h-[calc(100%-var(--tags-view-height)-var(--app-content-padding)-var(--app-content-padding)-var(--app-footer-height))]': + '!h-[calc(100%-var(--tags-view-height)-var(--app-content-padding)-var(--app-content-padding)-var(--app-footer-height))]': !fixedHeader && layout === 'topLeft' && footer, - '!min-h-[calc(100%-var(--top-tool-height)-var(--app-content-padding)-var(--app-content-padding))]': + '!h-[calc(100%-var(--top-tool-height)-var(--app-content-padding)-var(--app-content-padding))]': fixedHeader && layout === 'cutMenu' && footer, - '!min-h-[calc(100%-var(--top-tool-height)-var(--app-content-padding)-var(--app-content-padding)-var(--tags-view-height))]': + '!h-[calc(100%-var(--top-tool-height)-var(--app-content-padding)-var(--app-content-padding)-var(--tags-view-height))]': !fixedHeader && layout === 'cutMenu' && footer } ]" diff --git a/src/router/modules/remaining.ts b/src/router/modules/remaining.ts index bc62a3c4..6da3b0a4 100644 --- a/src/router/modules/remaining.ts +++ b/src/router/modules/remaining.ts @@ -70,6 +70,26 @@ const remainingRouter: AppRouteRecordRaw[] = [ } ] }, + { + path: '/ai/music', + component: Layout, + redirect: '/index', + name: 'AIMusic', + meta: {}, + children: [ + { + path: 'index', + component: () => import('@/views/ai/music/components/index.vue'), + name: 'AIMusicIndex', + meta: { + title: 'AI 音乐', + icon: 'ep:home-filled', + noCache: false, + affix: true + } + } + ] + }, { path: '/user', component: Layout, diff --git a/src/utils/dict.ts b/src/utils/dict.ts index ab6e2923..556c8d01 100644 --- a/src/utils/dict.ts +++ b/src/utils/dict.ts @@ -24,6 +24,10 @@ export interface NumberDictDataType extends DictDataType { value: number } +export interface StringDictDataType extends DictDataType { + value: string +} + export const getDictOptions = (dictType: string) => { return dictStore.getDictByType(dictType) || [] } @@ -44,8 +48,11 @@ export const getIntDictOptions = (dictType: string): NumberDictDataType[] => { } export const getStrDictOptions = (dictType: string) => { - const dictOption: DictDataType[] = [] + // 获得通用的 DictDataType 列表 const dictOptions: DictDataType[] = getDictOptions(dictType) + // 转换成 string 类型的 StringDictDataType 类型 + // why 需要特殊转换:避免 IDEA 在 v-for="dict in getStrDictOptions(...)" 时,el-option 的 key 会告警 + const dictOption: StringDictDataType[] = [] dictOptions.forEach((dict: DictDataType) => { dictOption.push({ ...dict, @@ -212,5 +219,8 @@ export enum DICT_TYPE { ERP_STOCK_RECORD_BIZ_TYPE = 'erp_stock_record_biz_type', // 库存明细的业务类型 // ========== AI - 人工智能模块 ========== - AI_PLATFORM = 'ai_platform' // AI 平台 + AI_PLATFORM = 'ai_platform', // AI 平台 + AI_IMAGE_STATUS = 'ai_image_status', // AI 图片状态 + AI_MUSIC_STATUS = 'ai_music_status', // AI 音乐状态 + AI_GENERATE_MODE = 'ai_generate_mode' // AI 生成模式 } diff --git a/src/views/ai/chat/ChatEmpty.vue b/src/views/ai/chat/ChatEmpty.vue new file mode 100644 index 00000000..4268b3d7 --- /dev/null +++ b/src/views/ai/chat/ChatEmpty.vue @@ -0,0 +1,79 @@ + + + diff --git a/src/views/ai/chat/Conversation.vue b/src/views/ai/chat/Conversation.vue new file mode 100644 index 00000000..2afeb9ac --- /dev/null +++ b/src/views/ai/chat/Conversation.vue @@ -0,0 +1,521 @@ + + + + + + diff --git a/src/views/ai/chat/Message.vue b/src/views/ai/chat/Message.vue new file mode 100644 index 00000000..942961ed --- /dev/null +++ b/src/views/ai/chat/Message.vue @@ -0,0 +1,322 @@ + + + + diff --git a/src/views/ai/chat/MessageLoading.vue b/src/views/ai/chat/MessageLoading.vue new file mode 100644 index 00000000..f3198cbd --- /dev/null +++ b/src/views/ai/chat/MessageLoading.vue @@ -0,0 +1,15 @@ + + + + + diff --git a/src/views/ai/chat/MessageNewChat.vue b/src/views/ai/chat/MessageNewChat.vue new file mode 100644 index 00000000..aac5f905 --- /dev/null +++ b/src/views/ai/chat/MessageNewChat.vue @@ -0,0 +1,50 @@ + + + + + diff --git a/src/views/ai/chat/components/ChatConversationUpdateForm.vue b/src/views/ai/chat/components/ChatConversationUpdateForm.vue index fe08ffb2..c9f5c849 100644 --- a/src/views/ai/chat/components/ChatConversationUpdateForm.vue +++ b/src/views/ai/chat/components/ChatConversationUpdateForm.vue @@ -8,7 +8,7 @@ v-loading="formLoading" > - + diff --git a/src/views/ai/chat/components/Header.vue b/src/views/ai/chat/components/Header.vue index 7d859c2b..17b1693b 100644 --- a/src/views/ai/chat/components/Header.vue +++ b/src/views/ai/chat/components/Header.vue @@ -45,6 +45,4 @@ defineProps({ flex-direction: row; } } - - diff --git a/src/views/ai/chat/components/MessageList.vue b/src/views/ai/chat/components/MessageList.vue deleted file mode 100644 index 0f77f8ec..00000000 --- a/src/views/ai/chat/components/MessageList.vue +++ /dev/null @@ -1,156 +0,0 @@ - - - - - diff --git a/src/views/ai/chat/index.vue b/src/views/ai/chat/index.vue index 0da53f1e..0910497a 100644 --- a/src/views/ai/chat/index.vue +++ b/src/views/ai/chat/index.vue @@ -1,179 +1,80 @@ + diff --git a/src/views/ai/chat/role/RoleList.vue b/src/views/ai/chat/role/RoleList.vue index 834eb3cb..25206cff 100644 --- a/src/views/ai/chat/role/RoleList.vue +++ b/src/views/ai/chat/role/RoleList.vue @@ -1,59 +1,72 @@ + diff --git a/src/views/ai/image/ImageDetailDrawer.vue b/src/views/ai/image/ImageDetailDrawer.vue new file mode 100644 index 00000000..fca087da --- /dev/null +++ b/src/views/ai/image/ImageDetailDrawer.vue @@ -0,0 +1,141 @@ + + + + diff --git a/src/views/ai/image/ImageTask.vue b/src/views/ai/image/ImageTask.vue new file mode 100644 index 00000000..e17354a4 --- /dev/null +++ b/src/views/ai/image/ImageTask.vue @@ -0,0 +1,244 @@ + + + + + + diff --git a/src/views/ai/image/ImageTaskCard.vue b/src/views/ai/image/ImageTaskCard.vue new file mode 100644 index 00000000..a8620b49 --- /dev/null +++ b/src/views/ai/image/ImageTaskCard.vue @@ -0,0 +1,145 @@ + + + + diff --git a/src/views/ai/image/dall3/index.vue b/src/views/ai/image/dall3/index.vue new file mode 100644 index 00000000..92071b7b --- /dev/null +++ b/src/views/ai/image/dall3/index.vue @@ -0,0 +1,398 @@ + + + + diff --git a/src/views/ai/image/index.vue b/src/views/ai/image/index.vue new file mode 100644 index 00000000..5293de52 --- /dev/null +++ b/src/views/ai/image/index.vue @@ -0,0 +1,105 @@ + + + + + + diff --git a/src/views/ai/image/manager/index.vue b/src/views/ai/image/manager/index.vue new file mode 100644 index 00000000..f0e94faa --- /dev/null +++ b/src/views/ai/image/manager/index.vue @@ -0,0 +1,250 @@ + + + diff --git a/src/views/ai/image/midjourney/index.vue b/src/views/ai/image/midjourney/index.vue new file mode 100644 index 00000000..7f288747 --- /dev/null +++ b/src/views/ai/image/midjourney/index.vue @@ -0,0 +1,384 @@ + + + + diff --git a/src/views/ai/image/stable-diffusion/index.vue b/src/views/ai/image/stable-diffusion/index.vue new file mode 100644 index 00000000..15a8cf4d --- /dev/null +++ b/src/views/ai/image/stable-diffusion/index.vue @@ -0,0 +1,405 @@ + + + + diff --git a/src/views/ai/model/chatModel/ChatModelForm.vue b/src/views/ai/model/chatModel/ChatModelForm.vue index cac3f772..e3f785c0 100644 --- a/src/views/ai/model/chatModel/ChatModelForm.vue +++ b/src/views/ai/model/chatModel/ChatModelForm.vue @@ -48,13 +48,29 @@ - + - + - + diff --git a/src/views/ai/music/components/list/audioBar/index.vue b/src/views/ai/music/components/list/audioBar/index.vue new file mode 100644 index 00000000..2b25e40f --- /dev/null +++ b/src/views/ai/music/components/list/audioBar/index.vue @@ -0,0 +1,9 @@ + + + diff --git a/src/views/ai/music/components/list/index.vue b/src/views/ai/music/components/list/index.vue new file mode 100644 index 00000000..6dce9b8c --- /dev/null +++ b/src/views/ai/music/components/list/index.vue @@ -0,0 +1,94 @@ + + + + + + diff --git a/src/views/ai/music/components/list/songCard/index.vue b/src/views/ai/music/components/list/songCard/index.vue new file mode 100644 index 00000000..dc1ffa8b --- /dev/null +++ b/src/views/ai/music/components/list/songCard/index.vue @@ -0,0 +1,29 @@ + + + diff --git a/src/views/ai/music/components/list/songInfo/index.vue b/src/views/ai/music/components/list/songInfo/index.vue new file mode 100644 index 00000000..4832bfcb --- /dev/null +++ b/src/views/ai/music/components/list/songInfo/index.vue @@ -0,0 +1,33 @@ + + + diff --git a/src/views/ai/music/components/mode/desc.vue b/src/views/ai/music/components/mode/desc.vue new file mode 100644 index 00000000..4488461e --- /dev/null +++ b/src/views/ai/music/components/mode/desc.vue @@ -0,0 +1,55 @@ + + + diff --git a/src/views/ai/music/components/mode/index.vue b/src/views/ai/music/components/mode/index.vue new file mode 100644 index 00000000..bb6cf116 --- /dev/null +++ b/src/views/ai/music/components/mode/index.vue @@ -0,0 +1,44 @@ + + + diff --git a/src/views/ai/music/components/mode/lyric.vue b/src/views/ai/music/components/mode/lyric.vue new file mode 100644 index 00000000..f774003a --- /dev/null +++ b/src/views/ai/music/components/mode/lyric.vue @@ -0,0 +1,83 @@ + + + diff --git a/src/views/ai/music/components/title/index.vue b/src/views/ai/music/components/title/index.vue new file mode 100644 index 00000000..a0658027 --- /dev/null +++ b/src/views/ai/music/components/title/index.vue @@ -0,0 +1,25 @@ + + + diff --git a/src/views/ai/music/manager/index.vue b/src/views/ai/music/manager/index.vue new file mode 100644 index 00000000..ec3c12b0 --- /dev/null +++ b/src/views/ai/music/manager/index.vue @@ -0,0 +1,285 @@ + + + diff --git a/src/views/infra/job/index.vue b/src/views/infra/job/index.vue index a9ab332b..29460030 100644 --- a/src/views/infra/job/index.vue +++ b/src/views/infra/job/index.vue @@ -235,11 +235,7 @@ const handleChangeStatus = async (row: JobApi.JobVO) => { message.success(text + '成功') // 刷新列表 await getList() - } catch { - // 取消后,进行恢复按钮 - row.status = - row.status === InfraJobStatusEnum.NORMAL ? InfraJobStatusEnum.STOP : InfraJobStatusEnum.NORMAL - } + } catch {} } /** 删除按钮操作 */