Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Make work with --skip-timestamps

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8098 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
commit 4a44dbb63d224125380fd2ea5d9c1dc76f885681 1 parent 96fa4a2
@dhh dhh authored
View
4 railties/lib/rails_generator/generators/components/model/templates/fixtures.yml
@@ -4,12 +4,16 @@ one:
<% for attribute in attributes -%>
<%= attribute.name %>: <%= attribute.default %>
<% end -%>
+<% unless options[:skip_timestamps] -%>
created_at: <%= Time.now.to_s(:db) %>
updated_at: <%= Time.now.to_s(:db) %>
+<% end -%>
two:
<%= class_name.constantize.primary_key %>: 2
<% for attribute in attributes -%>
<%= attribute.name %>: <%= attribute.default %>
<% end -%>
+<% unless options[:skip_timestamps] -%>
created_at: <%= Time.now.to_s(:db) %>
updated_at: <%= Time.now.to_s(:db) %>
+<% end -%>
Please sign in to comment.
Something went wrong with that request. Please try again.