From 96813a5e508a54257ef03be613a704f1f71af53d Mon Sep 17 00:00:00 2001 From: Star Rauchenberger Date: Sat, 21 Oct 2023 00:25:50 -0400 Subject: Added quotes database --- db/migrate/20231021020306_create_quotes.rb | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 db/migrate/20231021020306_create_quotes.rb (limited to 'db/migrate/20231021020306_create_quotes.rb') diff --git a/db/migrate/20231021020306_create_quotes.rb b/db/migrate/20231021020306_create_quotes.rb new file mode 100644 index 0000000..60424e5 --- /dev/null +++ b/db/migrate/20231021020306_create_quotes.rb @@ -0,0 +1,14 @@ +class CreateQuotes < ActiveRecord::Migration[7.0] + def change + create_table :quotes do |t| + t.text :content, null: false + t.string :state, null: false + t.string :submitter + t.text :notes, null: false + t.integer :upvotes, null: false, default: 0 + t.integer :downvotes, null: false, default: 0 + + t.timestamps + end + end +end -- cgit 1.4.1