feat(project) : add delete button for empty projects with confirmation modal
Adds taskCount virtual field on Project entity, delete button in ProjectDrawer (visible only when taskCount === 0), and a reusable ConfirmDeleteProjectModal. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -82,7 +82,7 @@ class Task
|
||||
#[Groups(['task:read', 'task:write'])]
|
||||
private ?TaskGroup $group = null;
|
||||
|
||||
#[ORM\ManyToOne(targetEntity: Project::class)]
|
||||
#[ORM\ManyToOne(targetEntity: Project::class, inversedBy: 'tasks')]
|
||||
#[ORM\JoinColumn(nullable: false, onDelete: 'CASCADE')]
|
||||
#[Groups(['task:read', 'task:write'])]
|
||||
private ?Project $project = null;
|
||||
|
||||
Reference in New Issue
Block a user