Files
kulakpos_web/public/restaurant/Modules/Accounting/app/Models/Account.php

29 lines
555 B
PHP

<?php
namespace Modules\Accounting\Models;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\HasMany;
class Account extends Model
{
protected $fillable = [
'restaurant_id',
'name',
'code',
'type',
'opening_balance',
'current_balance',
'status',
];
public const TABLE_NAME = 'accounts';
protected $table = self::TABLE_NAME;
public function transactionDetails(): HasMany
{
return $this->hasMany(TransactionDetail::class);
}
}