Sha256: bc75ac6c97be1cc982d4147b04527b2c93ef80d4334549013cd8fbddb49183d3

Contents?: true

Size: 258 Bytes

Versions: 4

Compression:

Stored size: 258 Bytes

Contents

class ShipPart < ActiveRecord::Base
  belongs_to :ship
  has_many :trinkets, :class_name => "Treasure", :as => :looter
  accepts_nested_attributes_for :trinkets, :allow_destroy => true
  accepts_nested_attributes_for :ship

  validates_presence_of :name
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
ibm_db-4.0.0-x86-mingw32 test/models/ship_part.rb
ibm_db-4.0.0 test/models/ship_part.rb
activejob-lock-0.0.2 rails/activerecord/test/models/ship_part.rb
activejob-lock-0.0.1 rails/activerecord/test/models/ship_part.rb