This commit is contained in:
lys 2025-10-15 17:49:17 +08:00
parent 4ac19f78fd
commit 1799d404bf
1 changed files with 3 additions and 2 deletions

View File

@ -71,6 +71,7 @@ export const exceptStr = (str) => {
};
export const paginationFun = (tableListPageObj, sizeChange, onChange, i18n = {}) => {
const pageSizeOptions= tableListPageObj?.pageSizeOptions || ["10", "20", "50", "100"];
return {
current: tableListPageObj.pageNum || tableListPageObj.current,
pageSize: tableListPageObj.size || tableListPageObj.pageSize,
@ -78,7 +79,7 @@ export const paginationFun = (tableListPageObj, sizeChange, onChange, i18n = {})
showTotal: total => `${i18n["共"] ? i18n["共"] : "共"} ${total} ${i18n["条"] ? i18n["条"] : "条"}`,
showQuickJumper: true,
showSizeChanger: true,
pageSizeOptions: ["10", "20", "50", "100"],
pageSizeOptions,
onShowSizeChange: (page, size) => {
const { total } = tableListPageObj;
sizeChange({