Sha256: 4bf98d819d47b910fd4e0358334acf0e4e3e663e059bc727d3a4f7da6e8a9fc2

Contents?: true

Size: 355 Bytes

Versions: 5

Compression:

Stored size: 355 Bytes

Contents

class CreateAvatars < ActiveRecord::Migration[5.1]
  def change
    create_table :avatars do |t|
      t.references :imageable, polymorphic: true, index: true
      t.attachment :uploaded_file
      t.integer :imageable_id, unsigned: true, index: true, limit: 3
      t.string :imageable_type, index: true

      t.timestamps null: false
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
digital_heroes_startkit-0.1.1.4 lib/generators/project/db/migrate/21_create_avatars.rb
digital_heroes_startkit-0.1.1.3 lib/generators/project/db/migrate/21_create_avatars.rb
digital_heroes_startkit-0.1.1.2 lib/generators/project/db/migrate/21_create_avatars.rb
digital_heroes_startkit-0.1.1.1 lib/generators/project/db/migrate/21_create_avatars.rb
digital_heroes_startkit-0.1.1 lib/generators/project/db/migrate/21_create_avatars.rb