From 44691a0bd73e30a9657bfbd6b1ca38492d60c3c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juanjo=20Baza=CC=81n?= Date: Thu, 20 Oct 2016 16:14:03 +0200 Subject: [PATCH] adds dates to polls --- db/migrate/20161020112156_add_dates_to_polls.rb | 6 ++++++ db/schema.rb | 6 ++++-- 2 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 db/migrate/20161020112156_add_dates_to_polls.rb diff --git a/db/migrate/20161020112156_add_dates_to_polls.rb b/db/migrate/20161020112156_add_dates_to_polls.rb new file mode 100644 index 000000000..d504930ae --- /dev/null +++ b/db/migrate/20161020112156_add_dates_to_polls.rb @@ -0,0 +1,6 @@ +class AddDatesToPolls < ActiveRecord::Migration + def change + add_column :polls, :starts_at, :datetime + add_column :polls, :ends_at, :datetime + end +end diff --git a/db/schema.rb b/db/schema.rb index 5d81903a1..d1862bf11 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 20160928113143) do +ActiveRecord::Schema.define(version: 20161020112156) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" @@ -294,7 +294,9 @@ ActiveRecord::Schema.define(version: 20160928113143) do end create_table "polls", force: :cascade do |t| - t.string "name" + t.string "name" + t.datetime "starts_at" + t.datetime "ends_at" end create_table "proposal_notifications", force: :cascade do |t|