Файловый менеджер - Редактировать - /home/clickysoft/public_html/calvary-p2.clickysoft.net/app/Models/Page.php
Назад
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; class Page extends Model { use HasFactory; protected $fillable = [ 'parent_id', 'type', 'content', 'created_at', 'updated_at', ]; public function sectionOne() { return $this->hasOne(Page::class, 'parent_id')->where('id', '=',3); } public function sectionTwo() { return $this->hasOne(Page::class, 'parent_id')->where('id', '=',4); } public function sectionThree() { return $this->hasOne(Page::class, 'parent_id')->where('id', '=',5); } public function sectionFour() { return $this->hasOne(Page::class, 'parent_id')->where('id', '=',6); } public function sectionFive() { return $this->hasOne(Page::class, 'parent_id')->where('id', '=',7); } public function sectionSix() { return $this->hasOne(Page::class, 'parent_id')->where('id', '=',8); } public function sectionSeven() { return $this->hasOne(Page::class, 'parent_id')->where('id', '=',9); } }
| ver. 1.4 |
Github
|
.
| PHP 8.1.29 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка