about summary refs log tree commit diff stats
path: root/db/migrate/20171015171554_rename_revision_hold_item.pokeviewer.rb
blob: f7246de639362a560d2cc4edfb15cc0efa3a0e73 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
# This migration comes from pokeviewer (originally 20170930213633)
class RenameRevisionHoldItem < ActiveRecord::Migration[5.1]
  def change
    change_table :pokeviewer_revisions do |t|
      t.rename :hold_item, :item_id
    end

    add_foreign_key :pokeviewer_revisions, :pokeviewer_items, column: :item_id
  end
end