From bea5058df80d3bda395f61e0e5dcf147d5dd7778 Mon Sep 17 00:00:00 2001 From: kuaifan Date: Tue, 11 Nov 2025 21:49:09 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=BC=98=E5=8C=96=E9=94=99=E8=AF=AF?= =?UTF-8?q?=E5=A4=84=E7=90=86=E9=80=BB=E8=BE=91=EF=BC=8C=E7=AE=80=E5=8C=96?= =?UTF-8?q?=E9=94=99=E8=AF=AF=E6=B6=88=E6=81=AF=E8=BE=93=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- resources/assets/js/components/AIAssistant.vue | 8 ++++---- resources/assets/js/pages/manage/application.vue | 3 +-- .../js/pages/manage/components/Forwarder/confirm.vue | 2 +- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/resources/assets/js/components/AIAssistant.vue b/resources/assets/js/components/AIAssistant.vue index fa70f7a06..509dd7878 100644 --- a/resources/assets/js/components/AIAssistant.vue +++ b/resources/assets/js/components/AIAssistant.vue @@ -228,7 +228,7 @@ export default { return; } $A.modalError({ - content: error?.msg || error || '获取模型列表失败', + content: error?.msg || '获取模型列表失败', onOk: _ => { this.showModal = false; }, @@ -367,7 +367,7 @@ export default { this.inputValue = ''; this.startStream(streamKey, responseEntry); } catch (error) { - const msg = error?.msg || error || '发送失败'; + const msg = error?.msg || '发送失败'; if (responseEntry) { this.markResponseError(responseEntry, msg); } @@ -697,7 +697,7 @@ export default { result.then(() => { this.closeAssistant(); }).catch(error => { - $A.modalError(error?.msg || error || '应用失败'); + $A.modalError(error?.msg || '应用失败'); }).finally(() => { response.applyLoading = false; }); @@ -707,7 +707,7 @@ export default { } } catch (error) { response.applyLoading = false; - $A.modalError(error?.msg || error || '应用错误'); + $A.modalError(error?.msg || '应用错误'); } }, diff --git a/resources/assets/js/pages/manage/application.vue b/resources/assets/js/pages/manage/application.vue index a186d5c0c..459b974a3 100644 --- a/resources/assets/js/pages/manage/application.vue +++ b/resources/assets/js/pages/manage/application.vue @@ -646,8 +646,7 @@ export default { }); this.appSorts = this.normalizeSortPayload(data?.sorts); } catch (error) { - const msg = error?.msg || error?.message; - msg && console.warn(msg); + console.warn(error?.msg || error); } finally { this.appSortLoading = false; this.appSortLoaded = true; diff --git a/resources/assets/js/pages/manage/components/Forwarder/confirm.vue b/resources/assets/js/pages/manage/components/Forwarder/confirm.vue index fbadb3d08..ec81b1bcc 100644 --- a/resources/assets/js/pages/manage/components/Forwarder/confirm.vue +++ b/resources/assets/js/pages/manage/components/Forwarder/confirm.vue @@ -266,7 +266,7 @@ export default { } catch (error) { $A.modalError({ language: false, - content: this.$L("AI开启新会话失败") + `: ${error.msg || error}`, + content: this.$L("AI开启新会话失败") + `: ${error.msg || 'Unknown Error'}`, }); reject(error); }