Permalink
Browse files

keep the created/update_at/on columns from being automatically shown …

…(Thanks to Jeff Smick)
  • Loading branch information...
1 parent 05ae54d commit 857cc41d447786edcb9893be2ae3404ca32f7136 @justinfrench committed Mar 24, 2009
Showing with 1 addition and 0 deletions.
  1. +1 −0 lib/formtastic.rb
View
1 lib/formtastic.rb
@@ -236,6 +236,7 @@ def inputs(*args, &block)
if args.empty?
args = @object.class.reflections.map { |n,_| n }
args += @object.class.content_columns.map(&:name)
+ args -= %w[created_at updated_at created_on updated_on]
end
contents = args.map { |method| input(method.to_sym) }

0 comments on commit 857cc41

Please sign in to comment.