class ESA::Chart

The Chart class represents an organized set of accounts in the system.

@author Lenno Nagel

Public Instance Methods

trial_balance() click to toggle source

The trial balance of all accounts in the system. This should always equal zero, otherwise there is an error in the system.

@example

>> chart.trial_balance.to_i
=> 0

@return [BigDecimal] The decimal value balance of all accounts

# File app/models/esa/chart.rb, line 34
def trial_balance
  self.amounts.balance
end

Private Instance Methods

initialize_defaults() click to toggle source
# File app/models/esa/chart.rb, line 40
def initialize_defaults
  self.name ||= "Chart of Accounts"
end