Pengajuan.php 758 Bytes
Newer Older
Siti Aisah committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
<?php

namespace App\Models\Admin;

use App\Traits\Uuid;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class Pengajuan extends Model
{
    use HasFactory;
    use Uuid;

    public $incrementing = false;
    protected $table = 'tr_pengajuan';
    protected $keyType = 'string';

    protected $fillable = [
        'id',
        'id_pengajuan',
        'judul',
Siti Aisah committed
22
        'peneliti',
Siti Aisah committed
23 24 25 26 27 28
        'klasifikasi',
        'tahun',
        'id_kategori',
        'file_ec',
        'no_sk'
    ];
Triyah Fatmawati committed
29 30 31 32 33 34 35 36

    public function rPenelaah() {
        return $this->hasOne(Penelaah::class, 'id_pengajuan', 'id');
    }

    public function kategori(){
        return $this->hasOne(MsKategori::class, 'id', 'id_kategori');
    }
Siti Aisah committed
37
}