Blame view
app/Models/Education.php
574 Bytes
00652ea57 Оптимизация запро... |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; class Education extends Model { use HasFactory; protected $fillable = [ 'name', |
01e6816d2 Добавление модели... |
14 15 16 17 18 19 |
'is_remove', 'address', 'telephone', 'email', 'text', 'image' |
00652ea57 Оптимизация запро... |
20 21 22 23 24 |
]; public function scopeActive($query) { return $query->where('is_remove', '=', '0'); } |
d152a3a68 Создание основных... |
25 26 27 28 |
public function program_education() { return $this->hasMany(ProgramEducation::class); } |
00652ea57 Оптимизация запро... |
29 |
} |