add post
This commit is contained in:
14
db/schema.rb
generated
14
db/schema.rb
generated
@@ -10,10 +10,20 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema[7.0].define(version: 2022_02_27_175028) do
|
||||
ActiveRecord::Schema[7.0].define(version: 2022_02_27_194054) do
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "plpgsql"
|
||||
|
||||
create_table "posts", force: :cascade do |t|
|
||||
t.text "content"
|
||||
t.bigint "user_id", null: false
|
||||
t.bigint "quoted_post_id"
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.index ["quoted_post_id"], name: "index_posts_on_quoted_post_id"
|
||||
t.index ["user_id"], name: "index_posts_on_user_id"
|
||||
end
|
||||
|
||||
create_table "user_follows", force: :cascade do |t|
|
||||
t.bigint "follower_id"
|
||||
t.bigint "followed_id"
|
||||
@@ -30,6 +40,8 @@ ActiveRecord::Schema[7.0].define(version: 2022_02_27_175028) do
|
||||
t.index ["username"], name: "index_users_on_username"
|
||||
end
|
||||
|
||||
add_foreign_key "posts", "posts", column: "quoted_post_id"
|
||||
add_foreign_key "posts", "users"
|
||||
add_foreign_key "user_follows", "users", column: "followed_id"
|
||||
add_foreign_key "user_follows", "users", column: "follower_id"
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user