update the match view
This commit is contained in:
1 parent
062c0e896f
commit
69f5df163a
14 files changed
+7331
-743
No files matched your search
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||
use Illuminate\Database\Eloquent\Relations\HasMany;
|
||||
|
||||
class MatchRound extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $fillable = [
|
||||
'video_id',
|
||||
'round_number',
|
||||
'name',
|
||||
];
|
||||
|
||||
public function video(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(Video::class);
|
||||
}
|
||||
|
||||
public function points(): HasMany
|
||||
{
|
||||
return $this->hasMany(MatchPoint::class, 'match_round_id')->orderBy('timestamp_seconds');
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user