Merge remote-tracking branch 'parent/main' into upstream-20240308

This commit is contained in:
KMY 2024-03-08 08:08:34 +09:00
commit fa96bf2e87
106 changed files with 1107 additions and 253 deletions

View file

@ -10,7 +10,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema[7.1].define(version: 2024_02_29_233617) do
ActiveRecord::Schema[7.1].define(version: 2024_03_04_090449) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"
@ -940,6 +940,40 @@ ActiveRecord::Schema[7.1].define(version: 2024_02_29_233617) do
t.index ["uri", "reason", "created_at"], name: "index_ngword_histories_on_uri_and_reason_and_created_at"
end
create_table "notification_permissions", force: :cascade do |t|
t.bigint "account_id", null: false
t.bigint "from_account_id", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["account_id"], name: "index_notification_permissions_on_account_id"
t.index ["from_account_id"], name: "index_notification_permissions_on_from_account_id"
end
create_table "notification_policies", force: :cascade do |t|
t.bigint "account_id", null: false
t.boolean "filter_not_following", default: false, null: false
t.boolean "filter_not_followers", default: false, null: false
t.boolean "filter_new_accounts", default: false, null: false
t.boolean "filter_private_mentions", default: true, null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["account_id"], name: "index_notification_policies_on_account_id", unique: true
end
create_table "notification_requests", id: :bigint, default: -> { "timestamp_id('notification_requests'::text)" }, force: :cascade do |t|
t.bigint "account_id", null: false
t.bigint "from_account_id", null: false
t.bigint "last_status_id", null: false
t.bigint "notifications_count", default: 0, null: false
t.boolean "dismissed", default: false, null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["account_id", "from_account_id"], name: "index_notification_requests_on_account_id_and_from_account_id", unique: true
t.index ["account_id", "id"], name: "index_notification_requests_on_account_id_and_id", order: { id: :desc }, where: "(dismissed = false)"
t.index ["from_account_id"], name: "index_notification_requests_on_from_account_id"
t.index ["last_status_id"], name: "index_notification_requests_on_last_status_id"
end
create_table "notifications", force: :cascade do |t|
t.bigint "activity_id", null: false
t.string "activity_type", null: false
@ -948,7 +982,9 @@ ActiveRecord::Schema[7.1].define(version: 2024_02_29_233617) do
t.bigint "account_id", null: false
t.bigint "from_account_id", null: false
t.string "type"
t.boolean "filtered", default: false, null: false
t.index ["account_id", "id", "type"], name: "index_notifications_on_account_id_and_id_and_type", order: { id: :desc }
t.index ["account_id", "id", "type"], name: "index_notifications_on_filtered", order: { id: :desc }, where: "(filtered = false)"
t.index ["activity_id", "activity_type"], name: "index_notifications_on_activity_id_and_activity_type"
t.index ["from_account_id"], name: "index_notifications_on_from_account_id"
end
@ -1617,6 +1653,12 @@ ActiveRecord::Schema[7.1].define(version: 2024_02_29_233617) do
add_foreign_key "mutes", "accounts", name: "fk_b8d8daf315", on_delete: :cascade
add_foreign_key "ng_rule_histories", "accounts"
add_foreign_key "ng_rule_histories", "ng_rules"
add_foreign_key "notification_permissions", "accounts"
add_foreign_key "notification_permissions", "accounts", column: "from_account_id"
add_foreign_key "notification_policies", "accounts"
add_foreign_key "notification_requests", "accounts", column: "from_account_id", on_delete: :cascade
add_foreign_key "notification_requests", "accounts", on_delete: :cascade
add_foreign_key "notification_requests", "statuses", column: "last_status_id", on_delete: :nullify
add_foreign_key "notifications", "accounts", column: "from_account_id", name: "fk_fbd6b0bf9e", on_delete: :cascade
add_foreign_key "notifications", "accounts", name: "fk_c141c8ee55", on_delete: :cascade
add_foreign_key "oauth_access_grants", "oauth_applications", column: "application_id", name: "fk_34d54b0a33", on_delete: :cascade