2023-11-15 08:05:46 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Modules\Writeoff\Entities;
|
|
|
|
|
|
|
|
class Rekening extends BaseModel
|
|
|
|
{
|
|
|
|
protected $table = 'rekening';
|
|
|
|
protected $fillable = [
|
|
|
|
'branch_id',
|
|
|
|
'debitur_id',
|
2024-02-02 02:37:45 +00:00
|
|
|
'loan_type_id',
|
2023-11-15 08:05:46 +00:00
|
|
|
'currency_id',
|
|
|
|
'nomor_rekening',
|
|
|
|
'status_rekening',
|
|
|
|
'status',
|
|
|
|
'limit_ref',
|
|
|
|
'registered_at',
|
|
|
|
'authorized_at',
|
|
|
|
'authorized_status',
|
|
|
|
'authorized_by',
|
|
|
|
];
|
|
|
|
|
|
|
|
public function branch()
|
|
|
|
{
|
|
|
|
return $this->belongsTo(Branch::class);
|
|
|
|
}
|
|
|
|
|
|
|
|
public function debitur()
|
|
|
|
{
|
|
|
|
return $this->belongsTo(Debitur::class);
|
|
|
|
}
|
|
|
|
|
2023-12-14 09:59:57 +00:00
|
|
|
public function loan_type()
|
2023-11-15 08:05:46 +00:00
|
|
|
{
|
2023-12-14 09:59:57 +00:00
|
|
|
return $this->belongsTo(LoanType::class);
|
2023-11-15 08:05:46 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
public function currency()
|
|
|
|
{
|
|
|
|
return $this->belongsTo(Currency::class);
|
|
|
|
}
|
|
|
|
|
2023-12-08 09:56:25 +00:00
|
|
|
public function hapusBuku()
|
|
|
|
{
|
|
|
|
return $this->hasOne(HapusBuku::class,'nomor_pinjaman','nomor_rekening');
|
|
|
|
}
|
|
|
|
|
2023-11-15 08:05:46 +00:00
|
|
|
}
|