2023-07-12 07:47:08 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2023-03-27 14:09:10 +00:00
|
|
|
class AddMovedToAccountIdToAccounts < ActiveRecord::Migration[5.2]
|
2017-11-18 18:39:02 +00:00
|
|
|
def change
|
|
|
|
add_column :accounts, :moved_to_account_id, :bigint, null: true, default: nil
|
2019-05-30 19:35:29 +00:00
|
|
|
safety_assured { add_foreign_key :accounts, :accounts, column: :moved_to_account_id, on_delete: :nullify }
|
2017-11-18 18:39:02 +00:00
|
|
|
end
|
|
|
|
end
|