From 75af4f07c00998dbf4cc060069393536483cecc1 Mon Sep 17 00:00:00 2001 From: cherishsince Date: Tue, 9 Jul 2024 20:14:15 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E8=A7=A3=E5=86=B3todo=E3=80=91isUser?= =?UTF-8?q?=20=E4=BF=AE=E6=94=B9=E4=B8=BA=20computed?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/ai/model/chatRole/ChatRoleForm.vue | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/src/views/ai/model/chatRole/ChatRoleForm.vue b/src/views/ai/model/chatRole/ChatRoleForm.vue index c33d289d..7815fd85 100644 --- a/src/views/ai/model/chatRole/ChatRoleForm.vue +++ b/src/views/ai/model/chatRole/ChatRoleForm.vue @@ -13,7 +13,7 @@ - + - + @@ -32,7 +32,7 @@ - + - + - + { - return type === 'my-create' || type === 'my-update' -} +const isUser = computed(() => { + return formType.value === 'my-create' || formType.value === 'my-update' +}) // TODO @fan:直接使用 formRules;只要隐藏掉的字段,它是不会校验的哈; const getFormRules = async (type: string) => {