skl/app/Models/Pelaporan.php

56 lines
1.0 KiB
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
class Pelaporan extends Model
{
use HasFactory;
protected $table = 'Pelaporan';
protected $primaryKey = 'PelaporanId';
protected $fillable = [
'PeriodePelaporanId',
'Tahun',
'PerusahaanId',
'SKL',
'SPL',
'SKL_IL',
'SKL_AL',
'SKL_LB3',
'SKL_SB',
'SKL_BS',
'SKL_STB',
'SKL_LP',
'SKL_KDM',
'SPL_AL',
'SPL_LB3',
'SPL_SB',
'SPL_BS',
'SPL_STB',
'SPL_LP',
'SPL_KDM',
'IsChecked',
];
/**
* Relasi ke PeriodePelaporan.
*/
public function periodePelaporan()
{
return $this->belongsTo(PeriodePelaporan::class, 'PeriodePelaporanId', 'PeriodePelaporanId');
}
/**
* Relasi ke Perusahaan.
*/
public function perusahaan()
{
return $this->belongsTo(Perusahaan::class, 'PerusahaanId', 'PerusahaanId');
}
}