Skip to content

Add Pagination and Search to Pass and Member Tables #83

Description

@Lakes41

Difficulty: Hard

Type: Feature

Summary

Add pagination, search, and filtering to pass and member management tables so the dashboard remains usable as mock or live datasets grow.

Current Behaviour

The passes and members pages render all returned records in a single table. There is no built-in search, status filter, role filter, pass status filter, or pagination control. This is acceptable for small mock data but will not scale for larger communities.

Expected Behaviour

Operators should be able to search and filter passes and members, view bounded result sets, and navigate through pages without loading or rendering every record at once.

Suggested Implementation

Add query state for search, status, role, and page controls. Start with client-side filtering for mock mode if needed, but design the route contract so server-side filtering can be used later. Extend /api/passes and /api/members to accept query parameters such as search, status, role, limit, and cursor or page. Return a typed paginated response with items, total, and nextCursor or pagination metadata.

Files or Areas Likely Affected

  • apps/dashboard/app/passes/page.tsx
  • apps/dashboard/app/members/page.tsx
  • apps/dashboard/app/api/passes/route.ts
  • apps/dashboard/app/api/members/route.ts
  • apps/dashboard/lib/repositories/types.ts
  • apps/dashboard/lib/repositories/adapters/mock.ts
  • apps/dashboard/components/
  • apps/dashboard/test/

Acceptance Criteria

  • Passes can be searched by name or description.
  • Passes can be filtered by status.
  • Members can be searched by name or wallet address.
  • Members can be filtered by status and role.
  • Tables render bounded pages instead of unbounded full lists.
  • API routes support pagination parameters.
  • Empty filtered results show a clear empty state.
  • Tests cover search, filters, pagination, and empty result cases.

Additional Notes

Keep the first version simple. A cursor-based contract is preferred if live APIs may later return large datasets.

Metadata

Metadata

Labels

GrantFox OSSIssue tracked in GrantFox OSSMaybe RewardedIssue may be eligible for a GrantFox rewardOfficial CampaignCampaign: Official Campaign

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions