Bugfixes & Model for participants
This commit is contained in:
@@ -12,6 +12,7 @@ use App\Scopes\InstancedModel;
|
||||
use DateTime;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsToMany;
|
||||
use Illuminate\Database\Eloquent\Relations\HasMany;
|
||||
|
||||
/**
|
||||
* @property string $tenant
|
||||
@@ -164,4 +165,8 @@ class Event extends InstancedModel
|
||||
return $this->belongsToMany(User::class, 'event_managers', 'event_id', 'user_id')
|
||||
->withTimestamps();
|
||||
}
|
||||
|
||||
public function participants() : hasMany {
|
||||
return $this->hasMany(EventParticipant::class);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user