Sha256: a5f36ca58576db12c12621fa5cfcedafabce3558966de147bd27e35979d7b792
Contents?: true
Size: 590 Bytes
Versions: 4
Compression:
Stored size: 590 Bytes
Contents
class <%= migration_name %> < ActiveRecord::Migration def self.up create_table :<%= table_name %> do |t| <% for attribute in attributes -%> t.<%= attribute.type %> :<%= attribute.name %> <% end -%> <% for attachment in attachments -%> t.string :<%= attachment %>_file_name t.string :<%= attachment %>_content_type t.integer :<%= attachment %>_file_size t.datetime :<%= attachment %>_updated_at <% end -%> <% unless options[:skip_timestamps] %> t.timestamps <% end -%> end end def self.down drop_table :<%= table_name %> end end
Version data entries
4 entries across 4 versions & 1 rubygems