first commit
This commit is contained in:
@@ -0,0 +1,49 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models\Verifikator;
|
||||
|
||||
use App\Models\DokSiremun\CatatanPengajuan;
|
||||
use App\Models\DokSiremun\LogPengajuan;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||
|
||||
class AnggotaSk extends Model
|
||||
{
|
||||
use HasFactory, SoftDeletes;
|
||||
|
||||
protected $table = 'verifikator.anggota_sks';
|
||||
protected $fillable = [
|
||||
'id',
|
||||
'id_sk',
|
||||
'id_sk_verifikator',
|
||||
'id_anggota_sk',
|
||||
'kategori_id',
|
||||
'rubrik_id',
|
||||
'posisi',
|
||||
'nip',
|
||||
'nama',
|
||||
'gol',
|
||||
'keterangan',
|
||||
'catatan',
|
||||
'jangka_waktu',
|
||||
'created_at',
|
||||
'updated_at',
|
||||
'deleted_at'
|
||||
];
|
||||
|
||||
function sk()
|
||||
{
|
||||
return $this->belongsTo(Sk::class, 'id_sk_verifikator', 'id');
|
||||
}
|
||||
|
||||
function logs()
|
||||
{
|
||||
return $this->morphMany(LogPengajuan::class, 'logable');
|
||||
}
|
||||
|
||||
function notes()
|
||||
{
|
||||
return $this->morphMany(CatatanPengajuan::class, 'noteable');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user