diff --git a/src/views/knowledgeLibrary/index.vue b/src/views/knowledgeLibrary/index.vue index 213129a7432f11509dce8c8421139674a305be1e..a718ab5a96b0e52f388a204b24601b4cc8ed1106 100644 --- a/src/views/knowledgeLibrary/index.vue +++ b/src/views/knowledgeLibrary/index.vue @@ -846,8 +846,7 @@ const handleMultipleSelect = () => { const handleQueryKbLibrary = (params: QueryKbRequest) => { loading.value = true; - const teamId = localStorage.getItem('teamId') ?? ''; - KbAppAPI.getKbLibrary({teamId ,...params}) + KbAppAPI.getKbLibrary({ teamId: route.query.id as string, ...params }) // 使用 computed 的 teamId .then((res: any) => { fileTableList.data = res?.kbList; totalCount.value = res?.total; @@ -1109,7 +1108,7 @@ const handleCloseSingleUpload = (taskId: string) => { const handleCloseAllTask=(type: ITaskType)=>{ taskExportLoading.value = true; KbAppAPI.stopAllTaskList({ - teamId:route.query.id as string, + teamId: route.query.id as string, taskType:type }).then(() => { handleInitExportTaskList(); @@ -1120,7 +1119,7 @@ const handleCloseAllTask=(type: ITaskType)=>{ const handleInitExportTaskList = () => { return KbAppAPI.queryTaskList({ - teamId:route.query.id as string, + teamId: route.query.id as string, taskType: 'kb_export', page: 1, pageSize: exportTaskPageSize.value, @@ -1278,7 +1277,7 @@ const isSearch = computed(()=>{ return Object.values(sortFilter.value).some(value => { if (typeof value === 'string') return value.trim() !== ''; return value !== null && value !== undefined; // 其他类型需非空 - }); + }) }) const handleInputSearch = debounce((e) => { @@ -1379,8 +1378,7 @@ const handleUploadMyFile = (options: any) => { KbAppAPI.importKbLibrary( { params:{ - teamId: route.query.id as string - }, + teamId: route.query.id as string }, data: { kb_packages: options.file?.raw, },