From 9cad4d60542fd0e530500db919a75f56928b854e Mon Sep 17 00:00:00 2001 From: cherishsince Date: Mon, 27 May 2024 17:01:04 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E5=A2=9E=E5=8A=A0=E3=80=91AI=20Image?= =?UTF-8?q?=20=E5=A2=9E=E5=8A=A0=E8=8E=B7=E5=8F=96=20image=20list=20?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/ai/image/index.ts | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/src/api/ai/image/index.ts b/src/api/ai/image/index.ts index b1d73f34..ba70c0bb 100644 --- a/src/api/ai/image/index.ts +++ b/src/api/ai/image/index.ts @@ -29,20 +29,9 @@ export interface ImageDallReqVO { // AI API 密钥 API export const ImageApi = { + // 获取 image 列表 getImageList: async (params: ImagePageReqVO) => { - return [ - { - id: 1, - prompt: '童话里的小屋是什么样子?', - status: 'todo', - errorMessage: 'error 未登录', - type: 'qinxi', - taskId: 111, - imageUrl: 'https://img.bigpt8.com/uploads/thumbnail/20240509/b7802797e5f709f35a451a1591d4d495.png', - platform: 'dr', - model: 'dr' - } - ] as ImageDetailVO[] + return await request.get({ url: `/ai/image/list`, params }) }, // 获取 image 详细信息 getImageDetail: async (id: number) => { @@ -59,6 +48,7 @@ export const ImageApi = { model: 'dr' } as ImageDetailVO }, + // dall2、dall3 调用 dall: async (data: ImageDallReqVO)=> { return await request.post({ url: `/ai/image/dall`, data }) },