<?php

namespace App\Models;

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

class Riwayat extends Model
{
    use HasFactory;

    protected $table = 'riwayat';

    protected $fillable = [
        'user_id',
        'nilai_akhir',
        'tingkat_pemahaman',
        'akurasi',
        'waktu_mengerjakan',
        'evaluasi'
    ];

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