Class: Plutus::Liability
- Defined in:
- app/models/plutus/liability.rb
Overview
The Liability class is an account type used to represents debts owed to outsiders.
Normal Balance
The normal balance on Liability accounts is a Credit.
Class Method Summary collapse
-
.balance(options = {}) ⇒ BigDecimal
This class method is used to return the balance of all Liability accounts.
Instance Method Summary collapse
-
#balance(options = {}) ⇒ BigDecimal
The balance of the account.
Methods inherited from Account
#credits_balance, #debits_balance, trial_balance
Class Method Details
.balance(options = {}) ⇒ BigDecimal
This class method is used to return the balance of all Liability accounts.
Contra accounts are automatically subtracted from the balance.
Takes an optional hash specifying :from_date and :to_date for calculating balances during periods. :from_date and :to_date may be strings of the form “yyyy-mm-dd” or Ruby Date objects
52 53 54 |
# File 'app/models/plutus/liability.rb', line 52 def self.balance(={}) super end |
Instance Method Details
#balance(options = {}) ⇒ BigDecimal
The balance of the account.
Liability accounts have normal credit balances, so the debits are subtracted from the credits unless this is a contra account, in which credits are subtracted from debits
Takes an optional hash specifying :from_date and :to_date for calculating balances during periods. :from_date and :to_date may be strings of the form “yyyy-mm-dd” or Ruby Date objects
31 32 33 |
# File 'app/models/plutus/liability.rb', line 31 def balance(={}) super end |