Class: CreateNiftyAttachmentsTable
- Inherits:
-
ActiveRecord::Migration
- Object
- ActiveRecord::Migration
- CreateNiftyAttachmentsTable
- Defined in:
- lib/nifty/attachments/migration.rb
Instance Method Summary collapse
Instance Method Details
#down ⇒ Object
12 13 14 |
# File 'lib/nifty/attachments/migration.rb', line 12 def down drop_table :nifty_attachments end |
#up ⇒ Object
3 4 5 6 7 8 9 10 |
# File 'lib/nifty/attachments/migration.rb', line 3 def up create_table :nifty_attachments do |t| t.integer :parent_id t.string :parent_type, :token, :digest, :role, :file_name, :file_type t.binary :data, :limit => 10.megabytes t. end end |