Ledger
class Ledger extends Model implements Segragatable
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 | ||
Carbon | $date | ||
string | $entry_type | ||
float | $amount | ||
Carbon | $destroyed_at | ||
Carbon | $deleted_at |
Methods
static void
object
attributes()
Ledger attributes.
BelongsTo
transaction()
Transaction
HasOne
postAccount()
Ledger Post Account.
HasOne
folioAccount()
Ledger Folio Account.
BelongsTo
lineItem()
Ledger LineItem.
string
hashed()
Hash Ledger contents
bool
save(array $options = [])
Add Ledger hash.
static float
contribution(Account $account, int $transactionId)
Get Account's contribution to the Transaction total amount.
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 ModelTablePrefix at line 20
getTable()
Determine the model table name
at line 96
static void
post(Transaction $transaction)
Create Ledger entries for the Transaction.
at line 139
object
attributes()
Ledger attributes.
at line 149
BelongsTo
transaction()
Transaction
at line 159
HasOne
postAccount()
Ledger Post Account.
at line 169
HasOne
folioAccount()
Ledger Folio Account.
at line 179
BelongsTo
lineItem()
Ledger LineItem.
at line 189
string
hashed()
Hash Ledger contents
at line 215
bool
save(array $options = [])
Add Ledger hash.
at line 235
static float
contribution(Account $account, int $transactionId)
Get Account's contribution to the Transaction total amount.
at line 262
static float
balance(Account $account, Carbon $startDate, Carbon $endDate)
Get Account's balance as at the given date.