Introduce places:cleanup command to remove unused venues and cities

- 🧹 Add `places:cleanup` console command for dry-run and forced deletion of venues (without course/bitcoin events) and cities (without venues/meetups).
- 🧪 Add feature tests for `places:cleanup`, covering dry-run, forced deletion, and scenarios ensuring retention of dependent records.
-  Add `bitcoinEvents` relationship to `Venue` model to support cleanup logic.
This commit is contained in:
HolgerHatGarKeineNode
2026-06-16 16:32:57 +02:00
parent 29628b41e9
commit ae5eae576c
3 changed files with 136 additions and 0 deletions
+5
View File
@@ -102,4 +102,9 @@ class Venue extends Model implements HasMedia
{
return $this->hasMany(CourseEvent::class);
}
public function bitcoinEvents(): HasMany
{
return $this->hasMany(BitcoinEvent::class);
}
}