Writeoff/Entities/Debitur.php

37 lines
797 B
PHP

<?php
namespace Modules\Writeoff\Entities;
class Debitur extends BaseModel
{
protected $table = 'debitur';
protected $fillable = [
'branch_id',
'kode',
'name',
'address',
'npwp',
'status',
'registered_at',
'authorized_at',
'authorized_status',
'authorized_by',
];
public function branch()
{
return $this->belongsTo(Branch::class);
}
public function rekenings()
{
return $this->hasMany(Rekening::class);
}
public function subrogasi_jamkrindo()
{
return $this->hasMany(SubrogasiJamkrindo::class, 'kode_debitur', 'kode');
}
}