1
0
Fork 0
This repository has been archived on 2023-03-27. You can view files and clone it, but cannot push or open issues or pull requests.
lpr-partynest/db/migrate/20181202021854_move_from_users_to_accounts.rb

16 lines
513 B
Ruby

# frozen_string_literal: true
class MoveFromUsersToAccounts < ActiveRecord::Migration[5.2]
def change
remove_foreign_key :passport_confirmations, :users
remove_foreign_key :user_roles, :users
rename_table :user_roles, :account_roles
rename_column :passport_confirmations, :user_id, :account_id
rename_column :account_roles, :user_id, :account_id
add_foreign_key :passport_confirmations, :accounts
add_foreign_key :account_roles, :accounts
end
end