Restore direct page navigation and result totals for game search pagination #992

Closed
opened 2026-10-24 09:25:06 -05:00 by Veilor · 2 comments
Member

The game search results currently expose only previous and next navigation, making it difficult to jump to a distant page or understand the result set size.

Restore Laravel paginator controls that show the current result range, total result count, total page count, and direct page links while preserving the existing search query and filters.

Scope

  • Update the game search results pagination rendering in the game search page.
  • Preserve search terms, filters, ordering, and pagination state when navigating between pages.
  • Add focused feature coverage for totals, page counts, direct page navigation, and boundary states.

Acceptance Criteria

  • Search results display the current result range and total number of matching results.
  • Search results display the total number of pages and direct links for available pages.
  • Selecting a page link loads the corresponding result page while retaining the submitted search criteria.
  • Previous and next controls remain available with correct disabled or hidden behavior at the first and last pages.
  • Pagination remains usable when there are zero results, one page of results, or many pages of results.

Test Coverage Required

  • Extend the existing game search feature test to assert result totals and page counts in the rendered response.
  • Assert that a direct page navigation request returns the expected page of matching games and preserves the search criteria.
  • Cover first-page, last-page, single-page, and empty-result pagination states.

Progress Checklist

  • Confirm the game search controller/query uses Laravel pagination and identifies the paginator view input.
  • Replace the limited previous/next presentation with the repository’s established full pagination presentation or an equivalent shared paginator.
  • Add or update feature tests for pagination metadata and direct page navigation.
  • Run the focused game search test and format only the changed PHP files.
The game search results currently expose only previous and next navigation, making it difficult to jump to a distant page or understand the result set size. Restore Laravel paginator controls that show the current result range, total result count, total page count, and direct page links while preserving the existing search query and filters. ## Scope - Update the game search results pagination rendering in the game search page. - Preserve search terms, filters, ordering, and pagination state when navigating between pages. - Add focused feature coverage for totals, page counts, direct page navigation, and boundary states. ## Acceptance Criteria - Search results display the current result range and total number of matching results. - Search results display the total number of pages and direct links for available pages. - Selecting a page link loads the corresponding result page while retaining the submitted search criteria. - Previous and next controls remain available with correct disabled or hidden behavior at the first and last pages. - Pagination remains usable when there are zero results, one page of results, or many pages of results. ## Test Coverage Required - Extend the existing game search feature test to assert result totals and page counts in the rendered response. - Assert that a direct page navigation request returns the expected page of matching games and preserves the search criteria. - Cover first-page, last-page, single-page, and empty-result pagination states. ## Progress Checklist - [x] Confirm the game search controller/query uses Laravel pagination and identifies the paginator view input. - [x] Replace the limited previous/next presentation with the repository’s established full pagination presentation or an equivalent shared paginator. - [x] Add or update feature tests for pagination metadata and direct page navigation. - [x] Run the focused game search test and format only the changed PHP files.
Codex changed title from Search result pagination should show how many pages and results to Restore direct page navigation and result totals for game search pagination 2026-10-26 11:06:42 -05:00
Codex self-assigned this 2026-10-27 10:30:39 -05:00
Member

Implemented and merged in PR #998 (merge revision 3d129125).

  • Restored Laravel length-aware pagination: exact matching totals, visible result ranges, total page counts, and direct numbered links. The joined paginator follows the supplied screenshot, with accessible chevrons/current-page indicators and wrapping controls on phones.
  • Search query parameters and existing relevance/tie-break ordering are preserved. Empty, single-page, full-page boundaries, and out-of-range requests are covered; out-of-range pages retain totals and offer navigation back to valid results.
  • Retained the existing covering search index and ID-only page selection, loading card data only for visible games. The earlier Previous/Next-only change addressed a slow count scan; read-only production samples now measured exact counts at 36–53 ms using the covering index. Full-request production latency remains a post-deployment check.
  • Verification: 77 focused search and pending-game workflow tests passed (797 assertions), including following rendered links, exact boundary control states, query preservation, index coverage, and result IDs. Pint, PHPStan, asset build, diff checks, and desktop/mobile Playwright checks passed.

All four progress checklist items are checked. No schema migration is required for this change; the existing games_search_covering_index must remain present. Rebuilt frontend assets must accompany the new paginator view. Development and production deployment follows this closeout.

Implemented and merged in PR #998 (merge revision `3d129125`). - Restored Laravel length-aware pagination: exact matching totals, visible result ranges, total page counts, and direct numbered links. The joined paginator follows the supplied screenshot, with accessible chevrons/current-page indicators and wrapping controls on phones. - Search query parameters and existing relevance/tie-break ordering are preserved. Empty, single-page, full-page boundaries, and out-of-range requests are covered; out-of-range pages retain totals and offer navigation back to valid results. - Retained the existing covering search index and ID-only page selection, loading card data only for visible games. The earlier Previous/Next-only change addressed a slow count scan; read-only production samples now measured exact counts at 36–53 ms using the covering index. Full-request production latency remains a post-deployment check. - Verification: 77 focused search and pending-game workflow tests passed (797 assertions), including following rendered links, exact boundary control states, query preservation, index coverage, and result IDs. Pint, PHPStan, asset build, diff checks, and desktop/mobile Playwright checks passed. All four progress checklist items are checked. No schema migration is required for this change; the existing `games_search_covering_index` must remain present. Rebuilt frontend assets must accompany the new paginator view. Development and production deployment follows this closeout.
Member

Deployed the issue #992 changes from merged PR #998 (3d129125b2c00f5d7b3affbe8cc29d00ce1b8f4e) to development and production.

  • Updated the search controller, search page, custom paginator, and rebuilt versioned frontend assets. Rebuilt Blade caches and gracefully reloaded PHP 8.5-FPM. No migrations, dependency changes, or environment changes were needed; the required covering index is present on both databases.
  • Verified deployed file and publicly served asset checksums. Live checks passed on both environments for homepage HTTP 200, exact search totals/page counts, direct page-two navigation with the search term preserved, and empty results.
  • This was a scoped patch preserving unrelated runtime files and development overlays. The deployment receipts/release manifests identify it as ee6b2847+issue992-3d129125, rather than claiming every intervening master change was deployed.
  • Rollback backups: development /home/mvgldev/deploy-backups/issue992-3d129125-xww3v2wu; production /home/mvgl/deploy-backups/issue992-3d129125-25fphwzd. Each contains original runtime files and manifests under before/, checksums, the resulting release manifest, and a deployment receipt. Retained old versioned assets support rollback. Restore the backed-up files/manifests, remove files absent in before-checksums.json, rebuild Blade caches for the correct environment, and gracefully reload PHP-FPM.
  • The first dev attempt rolled back safely because verification from web1's public IP hit the existing dev privacy redirect. Retried successfully with live verification from the workstation's authorized IP; access controls were not changed.
  • Sample production end-to-end search requests completed in approximately 814 ms for the first page and 317 ms for page two, including transport and application work. These are smoke-test samples, not concurrent-load benchmarks; the earlier exact-count query samples were 36–53 ms with covering-index use.

Local checkout is clean on master, synced to 3d129125. All checklist items are checked, status/done is set, and the issue is closed.

Deployed the issue #992 changes from merged PR #998 (`3d129125b2c00f5d7b3affbe8cc29d00ce1b8f4e`) to development and production. - Updated the search controller, search page, custom paginator, and rebuilt versioned frontend assets. Rebuilt Blade caches and gracefully reloaded PHP 8.5-FPM. No migrations, dependency changes, or environment changes were needed; the required covering index is present on both databases. - Verified deployed file and publicly served asset checksums. Live checks passed on both environments for homepage HTTP 200, exact search totals/page counts, direct page-two navigation with the search term preserved, and empty results. - This was a scoped patch preserving unrelated runtime files and development overlays. The deployment receipts/release manifests identify it as `ee6b2847+issue992-3d129125`, rather than claiming every intervening master change was deployed. - Rollback backups: development `/home/mvgldev/deploy-backups/issue992-3d129125-xww3v2wu`; production `/home/mvgl/deploy-backups/issue992-3d129125-25fphwzd`. Each contains original runtime files and manifests under `before/`, checksums, the resulting release manifest, and a deployment receipt. Retained old versioned assets support rollback. Restore the backed-up files/manifests, remove files absent in `before-checksums.json`, rebuild Blade caches for the correct environment, and gracefully reload PHP-FPM. - The first dev attempt rolled back safely because verification from web1's public IP hit the existing dev privacy redirect. Retried successfully with live verification from the workstation's authorized IP; access controls were not changed. - Sample production end-to-end search requests completed in approximately 814 ms for the first page and 317 ms for page two, including transport and application work. These are smoke-test samples, not concurrent-load benchmarks; the earlier exact-count query samples were 36–53 ms with covering-index use. Local checkout is clean on `master`, synced to `3d129125`. All checklist items are checked, `status/done` is set, and the issue is closed.
Sign in to join this conversation.
No milestone
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
MyVideoGameList/myvideogamelist.com#992
No description provided.