diff --git a/ui/src/components/ai-chat/component/answer-content/index.vue b/ui/src/components/ai-chat/component/answer-content/index.vue index da61feaab..7f09fa04c 100644 --- a/ui/src/components/ai-chat/component/answer-content/index.vue +++ b/ui/src/components/ai-chat/component/answer-content/index.vue @@ -9,7 +9,7 @@ class="content" @mouseup="openControl" :style="{ - 'padding-right': showAvatar ? 'var(--padding-left)' : '0' + 'padding-right': showUserAvatar ? 'var(--padding-left)' : '0' }" > @@ -52,7 +52,7 @@ class="content" :style="{ 'padding-left': showAvatar ? 'var(--padding-left)' : '0', - 'padding-right': showAvatar ? 'var(--padding-left)' : '0' + 'padding-right': showUserAvatar ? 'var(--padding-left)' : '0' }" > { return user.isEnterprise() ? props.application.show_avatar : true }) - +const showUserAvatar = computed(() => { + return user.isEnterprise() ? props.application.show_user_avatar : true +}) const chatMessage = (question: string, type: 'old' | 'new', other_params_data?: any) => { if (type === 'old') { add_answer_text_list(props.chatRecord.answer_text_list) diff --git a/ui/src/components/ai-chat/component/question-content/index.vue b/ui/src/components/ai-chat/component/question-content/index.vue index 9cb1dfdd3..33e01b816 100644 --- a/ui/src/components/ai-chat/component/question-content/index.vue +++ b/ui/src/components/ai-chat/component/question-content/index.vue @@ -93,6 +93,7 @@ const { user } = useStore() const showAvatar = computed(() => { return user.isEnterprise() ? props.application.show_user_avatar : true }) + const document_list = computed(() => { if (props.chatRecord?.upload_meta) { return props.chatRecord.upload_meta?.document_list || [] diff --git a/ui/src/views/chat/base/index.vue b/ui/src/views/chat/base/index.vue index e42bfb6b9..27be286f2 100644 --- a/ui/src/views/chat/base/index.vue +++ b/ui/src/views/chat/base/index.vue @@ -30,6 +30,8 @@ :available="applicationAvailable" :appId="applicationDetail?.id" :record="recordList" + :chatId="currentChatId" + @refresh="refresh" >