From cd629ebc2899c4bb30b51ce5f99a84574804f863 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期五, 31 七月 2026 15:40:21 +0800
Subject: [PATCH] 银川 1.API密钥管理页面开发联调 2.模型管理页面开发联调 3.知识库管理页面开发联调 4.通知公告页面开发联调
---
src/views/ai/knowledge/document/data.ts | 84 -----------------------------------------
1 files changed, 1 insertions(+), 83 deletions(-)
diff --git a/src/views/ai/knowledge/document/data.ts b/src/views/ai/knowledge/document/data.ts
index 69ccd43..5556582 100644
--- a/src/views/ai/knowledge/document/data.ts
+++ b/src/views/ai/knowledge/document/data.ts
@@ -2,90 +2,8 @@
import type { VxeTableGridOptions } from '#/adapter/vxe-table';
import type { AiKnowledgeDocumentApi } from '#/api/ai/knowledge/document';
-import { AiModelTypeEnum, CommonStatusEnum, DICT_TYPE } from '@vben/constants';
+import { CommonStatusEnum, DICT_TYPE } from '@vben/constants';
import { getDictOptions } from '@vben/hooks';
-
-import { z } from '#/adapter/form';
-import { getModelSimpleList } from '#/api/ai/model/model';
-
-/** 鏂板/淇敼鐨勮〃鍗� */
-export function useFormSchema(): VbenFormSchema[] {
- return [
- {
- component: 'Input',
- fieldName: 'id',
- dependencies: {
- triggerFields: [''],
- show: () => false,
- },
- },
- {
- component: 'Input',
- fieldName: 'name',
- label: '鐭ヨ瘑搴撳悕绉�',
- rules: 'required',
- },
- {
- fieldName: 'description',
- label: '鐭ヨ瘑搴撴弿杩�',
- component: 'Textarea',
- componentProps: {
- rows: 3,
- placeholder: '璇疯緭鍏ョ煡璇嗗簱鎻忚堪',
- },
- },
- {
- component: 'ApiSelect',
- fieldName: 'embeddingModelId',
- label: '鍚戦噺妯″瀷',
- componentProps: {
- api: () => getModelSimpleList(AiModelTypeEnum.EMBEDDING),
- labelField: 'name',
- valueField: 'id',
- allowClear: true,
- placeholder: '璇烽�夋嫨鍚戦噺妯″瀷',
- },
- rules: 'required',
- },
- {
- fieldName: 'topK',
- label: '妫�绱� topK',
- component: 'InputNumber',
- componentProps: {
- class: '!w-full',
- placeholder: '璇疯緭鍏ユ绱� topK',
- min: 0,
- max: 10,
- },
- rules: 'required',
- },
- {
- fieldName: 'similarityThreshold',
- label: '妫�绱㈢浉浼煎害闃堝��',
- component: 'InputNumber',
- componentProps: {
- class: '!w-full',
- placeholder: '璇疯緭鍏ユ绱㈢浉浼煎害闃堝��',
- min: 0,
- max: 1,
- step: 0.01,
- precision: 2,
- },
- rules: 'required',
- },
- {
- fieldName: 'status',
- label: '鏄惁鍚敤',
- component: 'RadioGroup',
- componentProps: {
- options: getDictOptions(DICT_TYPE.COMMON_STATUS, 'number'),
- buttonStyle: 'solid',
- optionType: 'button',
- },
- rules: z.number().default(CommonStatusEnum.ENABLE),
- },
- ];
-}
/** 鍒楄〃鐨勬悳绱㈣〃鍗� */
export function useGridFormSchema(): VbenFormSchema[] {
--
Gitblit v1.9.3