Преглед на файлове

增加模型角色的2d模型字段

liyanbo преди 10 месеца
родител
ревизия
0ae10a7941

+ 2 - 1
src/api/ai/chat/conversation/index.ts

@@ -9,7 +9,8 @@ export interface ChatConversationVO {
   roleId: number // 角色编号
   modelId: number // 模型编号
   model: string // 模型标志
-  modelPath: string // 模型路径
+  model2dPath: string // 2d模型路径
+  model3dPath: string // 3d模型路径
   temperature: number // 温度参数
   maxTokens: number // 单条回复的最大 Token 数量
   maxContexts: number // 上下文的最大 Message 数量

+ 2 - 0
src/api/ai/model/chatRole/index.ts

@@ -9,6 +9,8 @@ export interface ChatRoleVO {
   category: string // 角色类别
   sort: number // 角色排序
   description: string // 角色描述
+  model2dPath: string // 2D模型路径
+  model3dPath: string // 3D模型路径
   systemMessage: string // 角色设定
   welcomeMessage: string // 角色设定
   publicStatus: boolean // 是否公开

+ 0 - 1
src/views/ai/chat/index/components/conversation/ConversationList.vue

@@ -237,7 +237,6 @@ const createConversation = async () => {
   const conversationId = await ChatConversationApi.createChatConversationMy(
     {} as unknown as ChatConversationVO
   )
-  debugger
   // 2. 获取对话内容
   await getChatConversationList()
   // 3. 选中对话

+ 7 - 7
src/views/ai/model/chatRole/ChatRoleForm.vue

@@ -27,17 +27,17 @@
         <el-input v-model="formData.category" placeholder="请输入角色类别" />
       </el-form-item>
       <!-- 新增:2D模型上传 -->
-      <el-form-item label="2D模型" prop="modelPath" v-if="!isUser">
+      <el-form-item label="2D模型" prop="model2dPath" v-if="!isUser">
         <UploadImg
-          v-model="formData.modelPath"
+          v-model="formData.model2dPath"
           height="100px"
           width="100px"
           placeholder="上传2D平面模型(支持图片格式)"
         />
       </el-form-item>
       <el-form-item label="3d模型" prop="model" v-if="!isUser">
-<!--        <UploadModel v-model="formData.modelPath" />-->
-        <el-input v-model="formData.modelPath" placeholder="请输入3d模型名称" />
+<!--        <UploadModel v-model="formData.model3dPath" />-->
+        <el-input v-model="formData.model3dPath" placeholder="请输入3d模型名称" />
       </el-form-item>
       <el-form-item label="角色描述" prop="description">
         <el-input type="textarea" v-model="formData.description" placeholder="请输入角色描述" />
@@ -119,7 +119,7 @@ const formData = ref({
   avatar: undefined,
   category: undefined,
   model2dPath: undefined, // 新增2D模型路径字段
-  modelPath: undefined,
+  model3dPath: undefined, // 新增3D模型路径字段
   sort: undefined,
   description: undefined,
   systemMessage: undefined,
@@ -213,8 +213,8 @@ const resetForm = () => {
     name: undefined,
     avatar: undefined,
     category: undefined,
-    modelPath: undefined,
-    model2dPath: undefined, // 新增重置2D模型路径
+    model2dPath: undefined, // 新增2D模型路径字段
+    model3dPath: undefined, // 新增3D模型路径字段
     sort: undefined,
     description: undefined,
     systemMessage: undefined,