app/models/esa/account.rb in event_sourced_accounting-0.1.0 vs app/models/esa/account.rb in event_sourced_accounting-0.1.1

- old
+ new

@@ -1,5 +1,7 @@ +require 'esa/associations/amounts_extension' + module ESA # The Account class represents accounts in the system. Each account must be subclassed as one of the following types: # # TYPE | NORMAL BALANCE | DESCRIPTION # -------------------------------------------------------------------------- @@ -22,10 +24,10 @@ attr_accessible :chart, :type, :code, :name, :contra attr_accessible :chart, :type, :code, :name, :contra, :as => :admin attr_readonly :chart belongs_to :chart - has_many :amounts, :extend => Associations::AmountsExtension + has_many :amounts, :extend => ESA::Associations::AmountsExtension has_many :transactions, :through => :amounts, :source => :transaction enumerize :normal_balance, in: [:none, :debit, :credit] after_initialize :default_values