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