Bottaajat/cultura

View on GitHub
app/Models/Video.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class Video extends Model
{
     /**
     * The table associated with the model.
     *
     * @var string
     */
    protected $table = 'videos';
    protected $fillable = [ 'title','emb_src','desc','thumb' ];

    public function tasks()
    {
      return $this->hasMany('App\Models\Task');
    }
    
    public function school() {
      return $this->belongsTo('App\Models\School');
    }
    
}