Sha256: 870df1ad011400fa5a618c4615468679e0590ded0831d55ebf1988b7b0e152d9
Contents?: true
Size: 419 Bytes
Versions: 1
Compression:
Stored size: 419 Bytes
Contents
class Child < Amfetamine::Base @@children = [] # unrelated to relationships! attr_accessor :title, :description, :dummy_id belongs_to_resource :dummy def initialize(args={}) @@children << self super(args) end def self.children @@children ||= [] end def to_hash { :title => title, :description => description, :dummy_id => dummy_id, :id => id } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
amfetamine-0.1.5 | spec/dummy/child.rb |