Files
grecia/db/migrate/20180604173248_add_budget_to_polls.rb
Javi Martín 4b1cbb7db6 Use Rails 5 conventions in ballot migrations
These migrations and models were added after the Rails 5 branch was
created but before it was merged.
2019-04-24 19:24:01 +02:00

6 lines
155 B
Ruby

class AddBudgetToPolls < ActiveRecord::Migration[4.2]
def change
add_reference :polls, :budget, index: { unique: true }, foreign_key: true
end
end