<?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 SongGroup extends Model
{
    use HasFactory;

    protected $fillable = [
        'song_id',
        'name',
        'color',
        'order',
    ];

    public function song(): BelongsTo
    {
        return $this->belongsTo(Song::class);
    }

    public function slides(): HasMany
    {
        return $this->hasMany(SongSlide::class);
    }

    public function arrangementGroups(): HasMany
    {
        return $this->hasMany(SongArrangementGroup::class);
    }
}
