diff --git a/frontend/src/hooks/useFileManager.ts b/frontend/src/hooks/useFileManager.ts index d767275c..f4a75ac1 100644 --- a/frontend/src/hooks/useFileManager.ts +++ b/frontend/src/hooks/useFileManager.ts @@ -500,12 +500,17 @@ export const useFileManager = (instanceId?: string, daemonId?: string) => { const handleTableChange = (e: { current: number; pageSize: number }) => { selectedRowKeys.value = []; selectionData.value = []; - operationForm.value.name = ""; + // operationForm.value.name = ""; operationForm.value.current = e.current; operationForm.value.pageSize = e.pageSize; getFileList(); }; + const handleSearchChange = () =>{ + operationForm.value.current = 1; + getFileList(); + } + const getFileStatus = async () => { const { state, execute } = getFileStatusApi(); try { @@ -627,6 +632,7 @@ export const useFileManager = (instanceId?: string, daemonId?: string) => { downloadFile, handleChangeDir, handleTableChange, + handleSearchChange, getFileStatus, changePermission, toDisk, diff --git a/frontend/src/widgets/instance/FileManager.vue b/frontend/src/widgets/instance/FileManager.vue index ec6d7879..5631251d 100644 --- a/frontend/src/widgets/instance/FileManager.vue +++ b/frontend/src/widgets/instance/FileManager.vue @@ -70,6 +70,7 @@ const { beforeUpload, downloadFile, handleChangeDir, + handleSearchChange, selectedFile, rowClickTable, handleTableChange, @@ -383,7 +384,7 @@ onUnmounted(() => { v-model:value.trim.lazy="operationForm.name" :placeholder="t('TXT_CODE_7cad42a5')" allow-clear - @change="getFileList()" + @change="handleSearchChange()" >