'datetime', ]; } public function event(): BelongsTo { return $this->belongsTo(Event::class); } public function user(): BelongsTo { return $this->belongsTo(User::class)->withTrashed(); } public function deletedBy(): BelongsTo { return $this->belongsTo(User::class, 'deleted_by')->withTrashed(); } public function isDeleted(): bool { return $this->deleted_at !== null; } public function scopeVisible($query) { return $query->whereNull('deleted_at'); } }