Skip to content

Conversation

gilluminate
Copy link
Contributor

@gilluminate gilluminate commented Jul 18, 2025

Closes ENG-867

Description Of Changes

Updates the Action Center tables to persist row selections across pagination. This allows users to select items on multiple pages and perform bulk actions on the entire selection. The total count of selected items is now accurately displayed and updated as the user navigates through pages. Selections are reset when filters or tabs are changed to avoid unintended actions.

Code Changes

  • DiscoveredAssetsTable.tsx & DiscoveredSystemAggregateTable.tsx
    • Replaced selectedRows state array with a selectedRowsMap to store selections across all pages.
    • Updated the rowSelection.onChange logic to manage the selectedRowsMap, preserving selections when paginating.
    • Added a useEffect to sync the visible checkbox state (selectedRowKeys) with the persisted selections for the current page.
    • Updated the displayed count of selected items to reflect the total number of selections from all pages.

Steps to Confirm

  1. Visit the Vercel Nightly Build (link below)
  2. Go to the About page
  3. Enable "Web Monitor" and "Asset consent status labels" feature flags
  4. Visit the Action Center in left nav
  5. Click to "Review" the existing we monitor results for ethyca.com
  6. Click a System name in the left-most column
  7. Select a few rows on the first page.
  8. Navigate to the next page.
  9. Confirm the selected count still reflects the items chosen from the first page.
  10. Select a few more rows on the current page.
  11. Verify that the selected count now includes items from all pages.
  12. Go back to the first page and ensure the original selections are still checked.
  13. Perform a bulk action (e.g., "Assign a system") and confirm it applies to all selected items across all pages.
  14. Verify that selections are cleared after the action is successful.
  15. Change a switch to another tab and confirm that selections are cleared.

Pre-Merge Checklist

  • Issue requirements met
  • All CI pipelines succeeded
  • CHANGELOG.md updated
    • Add a db-migration This indicates that a change includes a database migration label to the entry if your change includes a DB migration
    • Add a high-risk This issue suggests changes that have a high-probability of breaking existing code label to the entry if your change includes a high-risk change (i.e. potential for performance impact or unexpected regression) that should be flagged
    • Updates unreleased work already in Changelog, no new entry necessary
  • Followup issues:
    • Followup issues created
    • No followup issues
  • Database migrations:
    • Ensure that your downrev is up to date with the latest revision on main
    • Ensure that your downgrade() migration is correct and works
      • If a downgrade migration is not possible for this change, please call this out in the PR description!
    • No migrations
  • Documentation:
    • Documentation complete, PR opened in fidesdocs
    • Documentation issue created in fidesdocs
    • If there are any new client scopes created as part of the pull request, remember to update public-facing documentation that references our scope registry
    • No documentation updates required

Copy link

vercel bot commented Jul 18, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
fides-plus-nightly ⬜️ Ignored (Inspect) Visit Preview Jul 18, 2025 7:41pm
fides-privacy-center ⬜️ Ignored (Inspect) Jul 18, 2025 7:41pm

Copy link
Contributor

@lucanovera lucanovera left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested the feature in nightly env and the selection now stays consistent across pagination changes. Code changes look good, approved!

@gilluminate gilluminate merged commit d1b54a0 into main Jul 18, 2025
23 of 24 checks passed
@gilluminate gilluminate deleted the gill/ENG-867/multi-select-needs-to-persist branch July 18, 2025 20:20
Copy link

cypress bot commented Jul 18, 2025

fides    Run #13138

Run Properties:  status check passed Passed #13138  •  git commit d1b54a0dfa: preserve selections across pages (#6357)
Project fides
Branch Review main
Run status status check passed Passed #13138
Run duration 00m 51s
Commit git commit d1b54a0dfa: preserve selections across pages (#6357)
Committer Jason Gill
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 0
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 5
View all changes introduced in this branch ↗︎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants