Allow closing accounts

Closes #37
This commit is contained in:
ricola 2026-04-20 14:17:52 -06:00
parent 1acc369774
commit 29bd105072
10 changed files with 115 additions and 15 deletions

View file

@ -0,0 +1,5 @@
class AddClosedAtToUser < ActiveRecord::Migration[7.2]
def change
add_column :users, :closed_at, :datetime
end
end

View file

@ -0,0 +1,5 @@
class AddOpenedAtToVote < ActiveRecord::Migration[7.2]
def change
add_column :votes, :opened_at, :datetime
end
end

View file

@ -10,7 +10,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema[7.2].define(version: 2026_03_23_215246) do
ActiveRecord::Schema[7.2].define(version: 2026_04_20_210736) do
create_table "candidates", force: :cascade do |t|
t.integer "vote_id"
t.string "name"
@ -46,6 +46,7 @@ ActiveRecord::Schema[7.2].define(version: 2026_03_23_215246) do
t.datetime "updated_at", null: false
t.string "reset"
t.boolean "admin"
t.datetime "closed_at"
end
create_table "votes", force: :cascade do |t|
@ -57,6 +58,7 @@ ActiveRecord::Schema[7.2].define(version: 2026_03_23_215246) do
t.datetime "updated_at", null: false
t.string "state"
t.integer "reminders"
t.datetime "opened_at"
end
add_foreign_key "ratings", "votes"