EasyCorp / EasyCorp/EasyAdminBundle
Collection::allowDelete should still allow deletion of unsaved items
Open
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 4.3k
- Forks
- 1.1k
- Avg merge
- 8d 2h
- Merged PRs (30d)
- 11
Description
Describe the bug
When you're editing an entity containing a collection of items that you want prohibit deletion, IMHO, the deletion should still be allowed while the item are added but not yet saved (only client-side).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing an EasyAdmin entity form with a collection configured with Collection::allowDelete disabled, then trace how newly added unsaved client-side items are handled. Add a regression test for the described distinction and verify that unsaved items can be deleted while persisted items remain protected.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php, symfony
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100