<?php

declare(strict_types=1);

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;

class GroupProjectArtwork extends Model
{
    use HasFactory;

    protected $fillable = [
        'group_project_id',
        'artwork_id',
        'sort_order',
    ];

    public function project(): BelongsTo
    {
        return $this->belongsTo(GroupProject::class, 'group_project_id');
    }

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