class CreateCompetitionPrizeUsers < ActiveRecord::Migration[5.2]
  def change
    create_table :competition_prize_users do |t|
      t.references :competition
      t.references :competition_team
      t.references :competition_prize
      t.references :user
      t.references :approver

      t.string :status
      t.integer :rank
      t.boolean :leader, default: false
      t.text :extra

      t.datetime :approved_at

      t.timestamps
    end
  end
end
