Ledger
class Ledger extends Model implements Segregatable
Class Ledger
Traits
Properties
| protected array | $fillable | The attributes that are mass assignable. |
|
| Entity | $entity | ||
| Transaction | $transaction | ||
| Vat | $vat | ||
| Account | $postAccount | ||
| Account | $folioAccount | ||
| LineItem | $lineItem | ||
| Currency | $currency | ||
| Carbon | $postingDate | ||
| string | $entryType | ||
| float | $amount | ||
| Carbon | $destroyed_at | ||
| Carbon | $deleted_at |
Methods
Add Ledger hash.
Hash Ledger contents
Create Ledger entries for the Assignments' Forex differences.
Get Account's contribution to the Transaction total amount.
Ledger attributes.
Transaction
Ledger Post Account.
Ledger Folio Account.
Ledger Folio Account.
Ledger LineItem.
Details
in
Segregating at line 28
static void
bootSegregating()
Register EntityScope for Model.
in
Segregating at line 46
BelongsTo
entity()
Model's Parent Entity.
in
ModelTablePrefix at line 22
getTable()
Determine the model table name
at line 259
static void
post(Transaction $transaction)
Create Ledger entries for the Transaction.
at line 274
bool
save(array $options = [])
Add Ledger hash.
at line 288
string
hashed()
Hash Ledger contents
at line 318
static void
postForex(Assignment $assignment, float $transactionRate, float $clearedRate)
Create Ledger entries for the Assignments' Forex differences.
at line 363
static float
contribution(Account $account, int $transactionId, int|null $currencyId = null)
Get Account's contribution to the Transaction total amount.
at line 393
static array
balance(Account $account, Carbon $startDate, Carbon $endDate, int|null $currencyId = null)
Get Account's balance as at the given date.
at line 429
object
attributes()
Ledger attributes.
at line 439
BelongsTo
transaction()
Transaction
at line 449
HasOne
postAccount()
Ledger Post Account.
at line 459
HasOne
folioAccount()
Ledger Folio Account.
at line 469
HasOne
currency()
Ledger Folio Account.
at line 479
BelongsTo
lineItem()
Ledger LineItem.