39 lines
772 B
PHP
39 lines
772 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|
|
|
/**
|
|
* @property int $order
|
|
* @property string $link
|
|
* @property string $video_link
|
|
* @property integer $video_size
|
|
* @property string $title
|
|
* @property string $duration
|
|
* @property integer $course_id
|
|
* @property bool $sync_offline
|
|
*/
|
|
class Chapter extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
protected $fillable = [
|
|
'order',
|
|
'link',
|
|
'video_link',
|
|
'video_size',
|
|
'title',
|
|
'duration',
|
|
'course_id',
|
|
'sync_offline',
|
|
];
|
|
|
|
public function course(): BelongsTo
|
|
{
|
|
return $this->belongsTo(Course::class);
|
|
}
|
|
}
|