<?php

namespace App\Models;

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

class Assessment extends Model
{
    use HasFactory;

    protected $fillable = [
    'user_id', 'subject_id', 'title', 'type', 'technique', 
    'total_score', // Baru
    'questions', 'rubric', 'remedial_plan', 
    'enrichment' // Baru
];

    public function subject()
    {
        return $this->belongsTo(Subject::class);
    }

    public function user()
    {
        return $this->belongsTo(User::class);
    }
}