Sha256: 7e3a092a8143d26d860e6148b37d6c8e0e90caa5818d7cdfb33a30d65f935b8d

Contents?: true

Size: 407 Bytes

Versions: 4

Compression:

Stored size: 407 Bytes

Contents

class SandboxyMigration < ActiveRecord::Migration<%= migration_version %>
    def self.up
        create_table :sandboxy, force: true do |t|
            t.references :sandboxed, polymorphic: true, null: false
            t.timestamps
        end

        add_index :sandboxy, ['sandboxed_id', 'sandboxed_type'], name: 'sandboxy_sandboxed'
    end

    def self.down
        drop_table :sandboxy
    end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
sandboxy-2.0.0 lib/generators/templates/migration.rb.erb
sandboxy-1.1.1 lib/generators/templates/migration.rb.erb
sandboxy-1.1.0 lib/generators/templates/migration.rb.erb
sandboxy-1.0.0 lib/generators/templates/migration.rb.erb