Class: CreateMedia
- Inherits:
-
ActiveRecord::Migration
- Object
- ActiveRecord::Migration
- CreateMedia
- Defined in:
- lib/generators/media/templates/medium.rb
Instance Method Summary collapse
Instance Method Details
#change ⇒ Object
2 3 4 5 6 7 8 9 10 11 12 |
# File 'lib/generators/media/templates/medium.rb', line 2 def change create_table :media do |t| t.string :title t.references :imageable, polymorphic: true, index: true t.string :medium t.string :lng_lat t.text :description t. null: false end end |