Sha256: 46a5a5d74a0d0720b4d5be359948ec688b811b4e0211571e5951773df3fddf4d

Contents?: true

Size: 447 Bytes

Versions: 3

Compression:

Stored size: 447 Bytes

Contents

module Plutus
  # The Amount class represents debit and credit amounts in the system.
  #
  # @abstract
  #   An amount must be a subclass as either a debit or a credit to be saved to the database. 
  #
  # @author Michael Bulat
  class Amount < ActiveRecord::Base
    belongs_to :entry, :class_name => 'Plutus::Entry'
    belongs_to :account, :class_name => 'Plutus::Account'

    validates_presence_of :type, :amount, :entry, :account
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
plutus-0.10.1 app/models/plutus/amount.rb
plutus-0.10.0 app/models/plutus/amount.rb
plutus-0.9.0 app/models/plutus/amount.rb