Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't register delete multiple records action when deleted filter is active #9170

Merged
merged 3 commits into from
Dec 20, 2024

Conversation

bosiraphael
Copy link
Contributor

Don't register delete multiple records action when deleted filter is active

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR modifies the delete action functionality to prevent users from attempting to delete records that have already been marked as deleted by checking the filter state.

  • Added check for deletedAt field metadata in useDeleteMultipleRecordsAction.tsx to prevent delete action registration when deleted filter is active
  • Incorporated filter state check into canDelete condition to improve user experience by avoiding invalid delete attempts
  • Enhanced action menu entry management by considering record deletion status before registration

1 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

Copy link
Contributor

@martmull martmull left a comment

Choose a reason for hiding this comment

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

Nice

@bosiraphael bosiraphael merged commit 1eee99c into main Dec 20, 2024
22 checks passed
@bosiraphael bosiraphael deleted the fix-delete-multiple-records-action branch December 20, 2024 14:49
samyakpiya pushed a commit to samyakpiya/twenty that referenced this pull request Dec 28, 2024
…active (twentyhq#9170)

Don't register delete multiple records action when deleted filter is
active
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants