Sha256: 8acfb3fd349e01d9d30c96b83868c19765224fd8a79b9f20562ced599f1deb84

Contents?: true

Size: 225 Bytes

Versions: 103

Compression:

Stored size: 225 Bytes

Contents

class Company < ActiveRecord::Base
  attr_protected :rating
  set_sequence_name :companies_nonstd_seq

  validates_presence_of :name
  def validate
    errors.add('rating', 'rating should not be 2') if rating == 2
  end  
end

Version data entries

103 entries across 103 versions & 9 rubygems

Version Path
amrita2-2.0.1 sample/depot/vendor/plugins/will_paginate/test/fixtures/company.rb
amrita2-2.0.2 sample/depot/vendor/plugins/will_paginate/test/fixtures/company.rb
backlog-0.0.0 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.0.1 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.0.2 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.0.5 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.0.4 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.1.1 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.1.0 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.1.2 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.2.0 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.2.1 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.0 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.3 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.1 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.2 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.4 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.5 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.6 vendor/rails/actionpack/test/fixtures/company.rb
backlog-0.3.8 vendor/rails/actionpack/test/fixtures/company.rb