app/models/plutus/account.rb in plutus-0.10.0 vs app/models/plutus/account.rb in plutus-0.10.1

- old
+ new

@@ -36,13 +36,13 @@ has_many :debit_entries, :through => :debit_amounts, :source => :entry, :class_name => 'Plutus::Entry' validates_presence_of :type if Plutus.enable_tenancy - include Tenancy + include Plutus::Tenancy else - include NoTenancy + include Plutus::NoTenancy end # The credit balance for the account. # # @example @@ -72,13 +72,13 @@ # >> Account.trial_balance.to_i # => 0 # # @return [BigDecimal] The decimal value balance of all accounts def self.trial_balance - unless self.new.class == Account + unless self.new.class == Plutus::Account raise(NoMethodError, "undefined method 'trial_balance'") else - Asset.balance - (Liability.balance + Equity.balance + Revenue.balance - Expense.balance) + Plutus::Asset.balance - (Plutus::Liability.balance + Plutus::Equity.balance + Plutus::Revenue.balance - Plutus::Expense.balance) end end end end