Module: SimpleAttachments::MigrationHelpers

Defined in:
lib/simple_attachments/migration_helpers.rb

Instance Method Summary collapse

Instance Method Details

#attachmentObject

Create attachment model columns



5
6
7
8
9
10
# File 'lib/simple_attachments/migration_helpers.rb', line 5

def attachment
  column(:filename, :string, :null => false)
  column(:mimetype, :string, :null => false)
  column(:filesize, :integer, :null => false)
  column(:filepath, :string, :null => false)
end