Sha256: 286b93f2d95e9eb9223cd083dd4810f3cf60599b1ea0c920178b240728e6af87

Contents?: true

Size: 359 Bytes

Versions: 94

Compression:

Stored size: 359 Bytes

Contents

class <%= migration_name %> < ActiveRecord::Migration[5.2]
  def self.up
    create_table :<%= table_name %> do |t|
<% for attribute in attributes -%>
      t.<%= attribute.type %> :<%= attribute.name %>
<% end -%>
<% unless options[:skip_timestamps] %>
      t.timestamps
<% end -%>
    end
  end

  def self.down
    drop_table :<%= table_name %>
  end
end

Version data entries

94 entries across 94 versions & 1 rubygems

Version Path
trusty-cms-7.0.9.1 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.11 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.10 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.9 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.8 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.7 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.6 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.5 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.4 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.3 lib/generators/extension_model/templates/migration.rb
trusty-cms-6.3.1 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.2 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.1 lib/generators/extension_model/templates/migration.rb
trusty-cms-7.0.0 lib/generators/extension_model/templates/migration.rb
trusty-cms-6.3 lib/generators/extension_model/templates/migration.rb
trusty-cms-6.2.1 lib/generators/extension_model/templates/migration.rb
trusty-cms-6.2.2.1 lib/generators/extension_model/templates/migration.rb
trusty-cms-6.2.0 lib/generators/extension_model/templates/migration.rb
trusty-cms-6.1.2 lib/generators/extension_model/templates/migration.rb
trusty-cms-6.1.1 lib/generators/extension_model/templates/migration.rb