File tree Expand file tree Collapse file tree 8 files changed +20
-10
lines changed
Expand file tree Collapse file tree 8 files changed +20
-10
lines changed Original file line number Diff line number Diff line change @@ -189,7 +189,9 @@ export class ChatInfo extends Chat {
189189 ds_type : string ,
190190 datasource_name : string ,
191191 datasource_exists : boolean ,
192- records : Array < ChatRecord >
192+ records : Array < ChatRecord > ,
193+ recommended_question ?: string | undefined ,
194+ recommended_generate ?: boolean | undefined
193195 )
194196 constructor (
195197 param1 ?: number | Chat ,
Original file line number Diff line number Diff line change 465465 "import" : " Import" ,
466466 "change_file" : " Change file" ,
467467 "data_import_completed" : " Data import completed" ,
468+ "notes_import_completed" : " Import of notes complete" ,
468469 "imported_100_data" : " Successfully imported {msg} data" ,
469470 "return_to_view" : " Return to view" ,
470471 "continue_importing" : " Continue importing" ,
Original file line number Diff line number Diff line change 465465 "import" : " 가져오기" ,
466466 "change_file" : " 파일 변경" ,
467467 "data_import_completed" : " 데이터 가져오기 완료" ,
468+ "notes_import_completed" : " 메모 가져오기 완료" ,
468469 "imported_100_data" : " 데이터 {msg}개를 성공적으로 가져왔습니다" ,
469470 "return_to_view" : " 돌아가서 보기" ,
470471 "continue_importing" : " 계속 가져오기" ,
850851 "to_doc" : " API 보기" ,
851852 "trigger_limit" : " 최대 {0}개의 API 키 생성 지원"
852853 }
853- }
854+ }
Original file line number Diff line number Diff line change 466466 "import" : " 导入" ,
467467 "change_file" : " 更换文件" ,
468468 "data_import_completed" : " 数据导入完成" ,
469+ "notes_import_completed" : " 备注导入完成" ,
469470 "imported_100_data" : " 成功导入数据 {msg} 条" ,
470471 "return_to_view" : " 返回查看" ,
471472 "continue_importing" : " 继续导入" ,
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ async function getRecommendQuestions(articles_number: number) {
5353 if (res .recommended_config === 2 ) {
5454 questions .value = res .questions
5555 } else if (currentChat .value .recommended_generate ) {
56- questions .value = currentChat .value .recommended_question
56+ questions .value = currentChat .value .recommended_question as string
5757 } else {
5858 getRecommendQuestionsLLM (articles_number )
5959 }
Original file line number Diff line number Diff line change @@ -107,9 +107,13 @@ const handleCurrentChange = (val: number) => {
107107
108108const fieldListComputed = computed (() => {
109109 const { currentPage, pageSize } = pageInfo
110- return fieldList .value
111- .filter ((ele : any ) => ele .field_name .toLowerCase ().includes (fieldName .value .toLowerCase ()))
112- .slice ((currentPage - 1 ) * pageSize , currentPage * pageSize )
110+ return fieldListTotalComputed .value .slice ((currentPage - 1 ) * pageSize , currentPage * pageSize )
111+ })
112+
113+ const fieldListTotalComputed = computed (() => {
114+ return fieldList .value .filter ((ele : any ) =>
115+ ele .field_name .toLowerCase ().includes (fieldName .value .toLowerCase ())
116+ )
113117})
114118
115119const init = (reset = false ) => {
@@ -319,7 +323,7 @@ const renderHeader = ({ column }: any) => {
319323}
320324const fieldNameSearch = debounce (() => {
321325 pageInfo .currentPage = 1
322- pageInfo .total = fieldListComputed .value .length
326+ pageInfo .total = fieldListTotalComputed .value .length
323327}, 100 )
324328const fieldName = ref (' ' )
325329const btnSelectClick = (val : any ) => {
Original file line number Diff line number Diff line change @@ -424,7 +424,8 @@ const onSuccess = (response: any) => {
424424 uploadLoading .value = false
425425}
426426
427- const onError = () => {
427+ const onError = (e : any ) => {
428+ ElMessage .error (e .toString ())
428429 uploadLoading .value = false
429430}
430431
Original file line number Diff line number Diff line change @@ -156,12 +156,12 @@ const customColorChange = (val: any) => {
156156}
157157
158158const setPageCustomColor = (val : any ) => {
159- const ele = document .querySelector (' .ui-main ' ) as HTMLElement
159+ const ele = document .querySelector (' .left-preview ' ) as HTMLElement
160160 setCurrentColor (val , ele )
161161}
162162
163163const setPageHeaderFontColor = (val : any ) => {
164- const ele = document .getElementsByClassName (' ui-main ' )[0 ] as HTMLElement
164+ const ele = document .getElementsByClassName (' left-preview ' )[0 ] as HTMLElement
165165 ele .style .setProperty (' --ed-text-color-primary' , val )
166166}
167167const resetSqlBotForm = (reset2Default ? : boolean ) => {
You can’t perform that action at this time.
0 commit comments