Sha256: 26ff7a89b43ef962869e8a1db1fca453f83d1416366a9a232381f8ed7ef8bcac

Contents?: true

Size: 344 Bytes

Versions: 8

Compression:

Stored size: 344 Bytes

Contents

class Contract < ActiveRecord::Base
  belongs_to :company
  belongs_to :developer
  belongs_to :firm, :foreign_key => 'company_id'

  before_save :hi
  after_save :bye

  attr_accessor :hi_count, :bye_count

  def hi
    @hi_count ||= 0
    @hi_count += 1
  end

  def bye
    @bye_count ||= 0
    @bye_count += 1
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
ibm_db-5.2.0-x86-mingw32 test/models/contract.rb
ibm_db-5.1.0-x86-mingw32 test/models/contract.rb
ibm_db-5.0.5-x86-mingw32 test/models/contract.rb
ibm_db-5.0.4-x86-mingw32 test/models/contract.rb
ibm_db-5.0.3-x86-mingw32 test/models/contract.rb
ibm_db-5.0.2-x86-mingw32 test/models/contract.rb
ibm_db-3.0.5-x86-mingw32 test/models/contract.rb
ibm_db-3.0.5 test/models/contract.rb