aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/CHANGELOG
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2004-12-16 03:23:06 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2004-12-16 03:23:06 +0000
commitf296e117c6fb771091a292e4b6d08355801ca3c6 (patch)
treefadbee05b39bc7346b19a353c865c33c84412096 /activerecord/CHANGELOG
parentf7f1fee7655d444269ad4b387c45cd4ed576809b (diff)
downloadrails-f296e117c6fb771091a292e4b6d08355801ca3c6.tar.gz
rails-f296e117c6fb771091a292e4b6d08355801ca3c6.tar.bz2
rails-f296e117c6fb771091a292e4b6d08355801ca3c6.zip
Added Base.validates_inclusion_of that validates whether the value of the specified attribute is available in a particular enumerable object. [what-a-day]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@179 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/CHANGELOG')
-rw-r--r--activerecord/CHANGELOG8
1 files changed, 8 insertions, 0 deletions
diff --git a/activerecord/CHANGELOG b/activerecord/CHANGELOG
index d80d3a7c86..e7399fb800 100644
--- a/activerecord/CHANGELOG
+++ b/activerecord/CHANGELOG
@@ -1,5 +1,13 @@
*CVS*
+* Added Base.validates_inclusion_of that validates whether the value of the specified attribute is available in a particular enumerable
+ object. [what-a-day]
+
+ class Person < ActiveRecord::Base
+ validates_inclusion_of :gender, :in=>%w( m f ), :message=>"woah! what are you then!??!!"
+ validates_inclusion_of :age, :in=>0..99
+ end
+
* Added acts_as_list that can decorates an existing class with methods like move_higher/lower, move_to_top/bottom. [Tobias Luetke] Example:
class TodoItem < ActiveRecord::Base