Fixed: can not save numeric, date and boolean custom fields (broken by r994).

git-svn-id: http://redmine.rubyforge.org/svn/trunk@996 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2007-12-14 21:47:57 +00:00
parent d1a3fbea40
commit 777edc13c1
1 changed files with 1 additions and 0 deletions

View File

@ -45,6 +45,7 @@ class CustomField < ActiveRecord::Base
self.possible_values = self.possible_values.collect{|v| v unless v.empty?}.compact
# make sure these fields are not searchable
self.searchable = false if %w(int float date bool).include?(field_format)
true
end
def validate