release: v3.4.1

This commit is contained in:
2024-12-08 20:11:02 +08:00
parent 7c509fa737
commit 206b92c2a2
5 changed files with 38 additions and 4 deletions

View File

@@ -57,6 +57,11 @@ export function useTable<T extends U, U = T>(api: Api<T>, options?: Options<T, U
pagination.onChange(1)
}
// 刷新
const refresh = () => {
getTableData()
}
// 删除
const handleDelete = async <T>(
deleteApi: () => Promise<ApiRes<T>>,
@@ -89,5 +94,5 @@ export function useTable<T extends U, U = T>(api: Api<T>, options?: Options<T, U
})
}
return { loading, tableData, getTableData, search, pagination, selectedKeys, select, selectAll, handleDelete }
return { loading, tableData, getTableData, search, pagination, selectedKeys, select, selectAll, handleDelete, refresh }
}