fix:[FL-157][搜索无结果时保持分页组件显示]

- 设置分页total最小值为1,确保即使数据为0时分页组件也显示
- showTotal显示真实的数据条数,不受最小值影响

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: multica-agent <github@multica.ai>
This commit is contained in:
chengkai3
2026-06-17 22:59:15 +08:00
parent cf5bbc3548
commit 9d6bd733a2
+2 -2
View File
@@ -748,10 +748,10 @@ export default function AdminUsersPage() {
pagination={{
current: pagination.current,
pageSize: pagination.pageSize,
total: usersQuery.data?.total ?? 0,
total: Math.max(usersQuery.data?.total ?? 0, 1),
showSizeChanger: true,
pageSizeOptions: [10, 20, 50, 100],
showTotal: (total) => `${total}`,
showTotal: (total) => `${usersQuery.data?.total ?? 0}`,
hideOnSinglePage: false,
style: { marginBottom: 0 },
onChange: (page, pageSize) => {