diff --git a/frontend/src/i18n/en.json b/frontend/src/i18n/en.json index e38487557..1d1ad17e5 100644 --- a/frontend/src/i18n/en.json +++ b/frontend/src/i18n/en.json @@ -635,6 +635,7 @@ "error": "Error", "exec-sql-err": "Execute SQL failed", "no_data": "No Data", + "loading_data": "Loading ...", "show_error_detail": "Show error info" }, "about": { diff --git a/frontend/src/i18n/ko-KR.json b/frontend/src/i18n/ko-KR.json index f38608401..286dcaaf9 100644 --- a/frontend/src/i18n/ko-KR.json +++ b/frontend/src/i18n/ko-KR.json @@ -635,6 +635,7 @@ "error": "오류", "exec-sql-err": "SQL 실행 실패", "no_data": "데이터가 없습니다", + "loading_data": "로딩 중 ...", "show_error_detail": "구체적인 정보 보기" }, "about": { @@ -733,4 +734,4 @@ "modelType": { "llm": "대형 언어 모델" } -} \ No newline at end of file +} diff --git a/frontend/src/i18n/zh-CN.json b/frontend/src/i18n/zh-CN.json index 9417002c2..b6e8c301a 100644 --- a/frontend/src/i18n/zh-CN.json +++ b/frontend/src/i18n/zh-CN.json @@ -635,6 +635,7 @@ "error": "错误", "exec-sql-err": "执行SQL失败", "no_data": "暂无数据", + "loading_data": "加载中...", "show_error_detail": "查看具体信息" }, "about": { @@ -733,4 +734,4 @@ "modelType": { "llm": "大语言模型" } -} \ No newline at end of file +} diff --git a/frontend/src/views/chat/answer/ChartAnswer.vue b/frontend/src/views/chat/answer/ChartAnswer.vue index 89e32f597..c424585fd 100644 --- a/frontend/src/views/chat/answer/ChartAnswer.vue +++ b/frontend/src/views/chat/answer/ChartAnswer.vue @@ -218,7 +218,10 @@ const sendMessage = async () => { } } +const loadingData = ref(false) + function getChatData(recordId?: number) { + loadingData.value = true chatApi .get_chart_data(recordId) .then((response) => { @@ -229,6 +232,7 @@ function getChatData(recordId?: number) { }) }) .finally(() => { + loadingData.value = false emits('scrollBottom') }) } @@ -254,7 +258,12 @@ defineExpose({ sendMessage, index: () => index.value, stop })