diff --git a/dbm-ui/frontend/src/components/cluster-common/big-data-host-table/hook/useLocalPagination.ts b/dbm-ui/frontend/src/components/cluster-common/big-data-host-table/hook/useLocalPagination.ts index 1f08de240c..ca182b5890 100644 --- a/dbm-ui/frontend/src/components/cluster-common/big-data-host-table/hook/useLocalPagination.ts +++ b/dbm-ui/frontend/src/components/cluster-common/big-data-host-table/hook/useLocalPagination.ts @@ -51,13 +51,16 @@ export default function (originalData: Ref) { const handlePaginationCurrentChange = (current: number) => { pagination.current = current; }; + const handlePaginationLimitChange = (limit: number) => { pagination.limit = limit; + pagination.current = 1; }; watch(searchKey, () => { pagination.current = 1; }); + watch( serachList, (list) => { diff --git a/dbm-ui/frontend/src/components/db-table/index.vue b/dbm-ui/frontend/src/components/db-table/index.vue index b79cde5607..ac35730505 100644 --- a/dbm-ui/frontend/src/components/db-table/index.vue +++ b/dbm-ui/frontend/src/components/db-table/index.vue @@ -528,6 +528,7 @@ // 切换每页条数 const handlePageLimitChange = (pageLimit: number) => { pagination.limit = pageLimit; + pagination.current = 1; fetchListData(); }; diff --git a/dbm-ui/frontend/src/hooks/useLocalPagination.ts b/dbm-ui/frontend/src/hooks/useLocalPagination.ts index bf701571d5..e37f45469a 100644 --- a/dbm-ui/frontend/src/hooks/useLocalPagination.ts +++ b/dbm-ui/frontend/src/hooks/useLocalPagination.ts @@ -51,6 +51,7 @@ export function useLocalPagination(originalData: Ref>, callback: (ru }; const handlePaginationLimitChange = (limit: number) => { pagination.limit = limit; + handlePaginationCurrentChange(1); }; watch(searchKey, () => { diff --git a/dbm-ui/frontend/src/views/inspection-manage/report/components/render-dynamic-table/Index.vue b/dbm-ui/frontend/src/views/inspection-manage/report/components/render-dynamic-table/Index.vue index 54e1af2db5..1ab25675fa 100644 --- a/dbm-ui/frontend/src/views/inspection-manage/report/components/render-dynamic-table/Index.vue +++ b/dbm-ui/frontend/src/views/inspection-manage/report/components/render-dynamic-table/Index.vue @@ -113,6 +113,7 @@ const pageLimitChange = (pageLimit: number) => { pagination.limit = pageLimit; + pagination.current = 1; fetchData(); }; diff --git a/dbm-ui/frontend/src/views/resource-manage/pool/host-list/components/RenderTable.vue b/dbm-ui/frontend/src/views/resource-manage/pool/host-list/components/RenderTable.vue index 6cc0287bf2..f751330827 100644 --- a/dbm-ui/frontend/src/views/resource-manage/pool/host-list/components/RenderTable.vue +++ b/dbm-ui/frontend/src/views/resource-manage/pool/host-list/components/RenderTable.vue @@ -459,6 +459,7 @@ // 切换每页条数 const handlePageLimitChange = (pageLimit: number) => { pagination.limit = pageLimit; + pagination.current = 1; fetchListData(); };