[Opda-develop] OPDA/app/models channel.rb,1.2,1.3
Brought to you by:
digitalpodcast
|
From: Alex N. <dig...@us...> - 2006-08-31 05:29:14
|
Update of /cvsroot/opda/OPDA/app/models In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv16754/app/models Modified Files: channel.rb Log Message: mods to add explicit types Index: channel.rb =================================================================== RCS file: /cvsroot/opda/OPDA/app/models/channel.rb,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** channel.rb 6 Jul 2006 04:22:01 -0000 1.2 --- channel.rb 31 Aug 2006 05:29:11 -0000 1.3 *************** *** 2,10 **** acts_as_taggable has_many :items - belongs_to :explicit_type belongs_to :user has_and_belongs_to_many :opml_feeds - has_and_belongs_to_many :categories has_and_belongs_to_many :subscription_lists has_many :channel_ratings end \ No newline at end of file --- 2,14 ---- acts_as_taggable has_many :items belongs_to :user has_and_belongs_to_many :opml_feeds has_and_belongs_to_many :subscription_lists has_many :channel_ratings + + def self.explicit_types + ["clean", "no", "yes"] + end + # validates_inclusion_of :explicit_types, :in => explicit_types, :message => "must be in #{explicit_types.join(',')}" + end \ No newline at end of file |