Account
class Account extends Model implements Recyclable, Segragatable
Class Account
Traits
Constants
NON_CURRENT_ASSET |
Account Type. |
CONTRA_ASSET |
|
INVENTORY |
|
BANK |
|
CURRENT_ASSET |
|
RECEIVABLE |
|
NON_CURRENT_LIABILITY |
|
CONTROL_ACCOUNT |
|
CURRENT_LIABILITY |
|
PAYABLE |
|
EQUITY |
|
OPERATING_REVENUE |
|
OPERATING_EXPENSE |
|
NON_OPERATING_REVENUE |
|
DIRECT_EXPENSE |
|
OVERHEAD_EXPENSE |
|
OTHER_EXPENSE |
|
RECONCILIATION |
|
Properties
protected array | $fillable | The attributes that are mass assignable. | |
Entity | $entity | ||
Category | $category | ||
Currency | $currency | ||
int|null | $code | ||
string | $name | ||
string | $description | ||
string | $account_type | ||
Carbon | $destroyed_at | ||
Carbon | $deleted_at | ||
float | $openingBalance | ||
float | $currentBalance | ||
float | $closingBalance |
Methods
Construct new Account.
Get Human Readable Account Type.
Get Human Readable Account types
Chart of Account Section Balances for the Reporting Period.
Account Currency.
Account Category.
Account Balances.
Account attributes.
Get Account's Opening Balance for the Reporting Period.
Get Account's Closing Balance for the Reporting Period.
Calculate Account Code.
Check for Current Year Transactions.
Details
in Segragating at line 29
static null
bootSegragating()
Register EntityScope for Model.
in Segragating at line 54
HasOne
entity()
Model's Parent Entity.
in Recycling at line 26
static void
bootRecycling()
Model recycling events.
in Recycling at line 69
MorphMany
recycled()
Recycled Model records.
in ModelTablePrefix at line 20
getTable()
Determine the model table name
at line 94
__construct($attributes = [])
Construct new Account.
at line 109
static string
getType(string $type)
Get Human Readable Account Type.
at line 121
static array
getTypes(array $types)
Get Human Readable Account types
at line 140
static array
sectionBalances(string $accountType, string $startDate = null, string $endDate = null)
Chart of Account Section Balances for the Reporting Period.
at line 179
BelongsTo
currency()
Account Currency.
at line 189
BelongsTo
category()
Account Category.
at line 199
HasMany
balances()
Account Balances.
at line 209
object
attributes()
Account attributes.
at line 222
float
openingBalance(string $year = null)
Get Account's Opening Balance for the Reporting Period.
at line 244
float
closingBalance(string $startDate = null, string $endDate = null)
Get Account's Closing Balance for the Reporting Period.
at line 257
bool
save(array $options = [])
Calculate Account Code.
at line 277
bool
delete()
Check for Current Year Transactions.