engine/vendor/plugins/custom_fields/spec/models/project.rb
Jacques Crocker 8a17394223 Updating to the latest Mongoid association syntax
has_many_related => references_many
belongs_to_related => referenced_in
2010-07-30 19:15:24 -07:00

18 lines
323 B
Ruby

class Project
include Mongoid::Document
include CustomFields::ProxyClassEnabler
include CustomFields::CustomFieldsFor
field :name
field :description
references_many :people
embeds_many :tasks
custom_fields_for :people
custom_fields_for :tasks
named_scope :ordered, :order_by => [[:name, :asc]]
end