|
|
@ -192,8 +192,8 @@ export function useViewData( |
|
|
|
|
|
|
|
|
|
|
|
// to cater the case like when querying with a non-zero offset
|
|
|
|
// to cater the case like when querying with a non-zero offset
|
|
|
|
// the result page may point to the target page where the actual returned data don't display on
|
|
|
|
// the result page may point to the target page where the actual returned data don't display on
|
|
|
|
const expectedPage = Math.ceil(paginationData.value.totalRows! / paginationData.value.pageSize!) |
|
|
|
const expectedPage = Math.max(1, Math.ceil(paginationData.value.totalRows! / paginationData.value.pageSize!)) |
|
|
|
if (Math.max(1, expectedPage) < paginationData.value.page!) { |
|
|
|
if (expectedPage < paginationData.value.page!) { |
|
|
|
await changePage(expectedPage) |
|
|
|
await changePage(expectedPage) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|