Chore: Switch from Carrierwave to ActiveStorage (#393)

This commit is contained in:
Sojan Jose
2020-01-07 22:59:17 +05:30
committed by Pranav Raj S
parent f02d422b6a
commit f875a09fb7
29 changed files with 192 additions and 164 deletions

View File

@@ -0,0 +1,7 @@
class RemoveCarrierWaveAttributes < ActiveRecord::Migration[6.0]
def change
remove_column :contacts, :avatar, :string
remove_column :channel_facebook_pages, :avatar, :string
remove_column :attachments, :file, :string
end
end

View File

@@ -10,7 +10,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 2019_12_09_202758) do
ActiveRecord::Schema.define(version: 2019_12_27_191631) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"
@@ -43,7 +43,6 @@ ActiveRecord::Schema.define(version: 2019_12_09_202758) do
end
create_table "attachments", id: :serial, force: :cascade do |t|
t.string "file"
t.integer "file_type", default: 0
t.string "external_url"
t.float "coordinates_lat", default: 0.0
@@ -72,7 +71,6 @@ ActiveRecord::Schema.define(version: 2019_12_09_202758) do
t.integer "account_id", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.string "avatar"
t.index ["page_id", "account_id"], name: "index_channel_facebook_pages_on_page_id_and_account_id", unique: true
t.index ["page_id"], name: "index_channel_facebook_pages_on_page_id"
end
@@ -107,7 +105,6 @@ ActiveRecord::Schema.define(version: 2019_12_09_202758) do
t.integer "account_id", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.string "avatar"
t.string "pubsub_token"
t.index ["account_id"], name: "index_contacts_on_account_id"
t.index ["pubsub_token"], name: "index_contacts_on_pubsub_token", unique: true