Change older Paperclip database migrations for consistency (#30204)
This commit is contained in:
parent
2bcbeed951
commit
00cf8d3748
8 changed files with 48 additions and 8 deletions
|
@ -2,7 +2,12 @@
|
|||
|
||||
class AddThumbnailColumnsToMediaAttachments < ActiveRecord::Migration[5.2]
|
||||
def up
|
||||
add_attachment :media_attachments, :thumbnail
|
||||
# The following corresponds to `add_attachment :media_attachments, :thumbnail` in an older version of Paperclip
|
||||
add_column :media_attachments, :thumbnail_file_name, :string
|
||||
add_column :media_attachments, :thumbnail_content_type, :string
|
||||
add_column :media_attachments, :thumbnail_file_size, :integer
|
||||
add_column :media_attachments, :thumbnail_updated_at, :datetime
|
||||
|
||||
add_column :media_attachments, :thumbnail_remote_url, :string
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue