:::

2-3 /app/Test.php

<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class Test extends Model
{
    protected $fillable = [
        'content', 'user_id', 'exam_id', 'score', 'grade', 'class', 'num',
    ];

    public function exam()
    {
        return $this->belongsTo('App\Exam');
    }

    public function user()
    {
        return $this->belongsTo('App\User');
    }
}

 


:::

書籍目錄

展開 | 闔起

https%3A%2F%2Fcampus-xoops.tn.edu.tw%2Fmodules%2Ftad_book3%2Fpage.php%3Ftbsn%3D41%26tbdsn%3D1323

計數器

今天: 1210121012101210
昨天: 1956195619561956
總計: 6225865622586562258656225865622586562258656225865