<?php

namespace App;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class ForumFrontend extends Model
{
    use HasFactory;

    protected $table = "forum_frontends";
    protected $fillable = ['judul', 'konten', 'user_id'];

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

    public function komentar(){
        return $this->hasMany('App\Komentar');
    }

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