mirror of
https://github.com/mastodon/mastodon.git
synced 2024-12-23 00:30:57 +01:00
Update schema to reflect full db:migrate
run results (#31128)
This commit is contained in:
parent
4d374cf730
commit
34626b8291
1 changed files with 13 additions and 13 deletions
26
db/schema.rb
26
db/schema.rb
|
@ -194,8 +194,8 @@ ActiveRecord::Schema[7.1].define(version: 2024_07_13_171909) do
|
||||||
t.integer "avatar_storage_schema_version"
|
t.integer "avatar_storage_schema_version"
|
||||||
t.integer "header_storage_schema_version"
|
t.integer "header_storage_schema_version"
|
||||||
t.string "devices_url"
|
t.string "devices_url"
|
||||||
t.integer "suspension_origin"
|
|
||||||
t.datetime "sensitized_at", precision: nil
|
t.datetime "sensitized_at", precision: nil
|
||||||
|
t.integer "suspension_origin"
|
||||||
t.boolean "trendable"
|
t.boolean "trendable"
|
||||||
t.datetime "reviewed_at", precision: nil
|
t.datetime "reviewed_at", precision: nil
|
||||||
t.datetime "requested_review_at", precision: nil
|
t.datetime "requested_review_at", precision: nil
|
||||||
|
@ -579,12 +579,12 @@ ActiveRecord::Schema[7.1].define(version: 2024_07_13_171909) do
|
||||||
end
|
end
|
||||||
|
|
||||||
create_table "ip_blocks", force: :cascade do |t|
|
create_table "ip_blocks", force: :cascade do |t|
|
||||||
t.datetime "created_at", precision: nil, null: false
|
|
||||||
t.datetime "updated_at", precision: nil, null: false
|
|
||||||
t.datetime "expires_at", precision: nil
|
|
||||||
t.inet "ip", default: "0.0.0.0", null: false
|
t.inet "ip", default: "0.0.0.0", null: false
|
||||||
t.integer "severity", default: 0, null: false
|
t.integer "severity", default: 0, null: false
|
||||||
|
t.datetime "expires_at", precision: nil
|
||||||
t.text "comment", default: "", null: false
|
t.text "comment", default: "", null: false
|
||||||
|
t.datetime "created_at", precision: nil, null: false
|
||||||
|
t.datetime "updated_at", precision: nil, null: false
|
||||||
t.index ["ip"], name: "index_ip_blocks_on_ip", unique: true
|
t.index ["ip"], name: "index_ip_blocks_on_ip", unique: true
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -1421,9 +1421,9 @@ ActiveRecord::Schema[7.1].define(version: 2024_07_13_171909) do
|
||||||
add_index "instances", ["domain"], name: "index_instances_on_domain", unique: true
|
add_index "instances", ["domain"], name: "index_instances_on_domain", unique: true
|
||||||
|
|
||||||
create_view "user_ips", sql_definition: <<-SQL
|
create_view "user_ips", sql_definition: <<-SQL
|
||||||
SELECT t0.user_id,
|
SELECT user_id,
|
||||||
t0.ip,
|
ip,
|
||||||
max(t0.used_at) AS used_at
|
max(used_at) AS used_at
|
||||||
FROM ( SELECT users.id AS user_id,
|
FROM ( SELECT users.id AS user_id,
|
||||||
users.sign_up_ip AS ip,
|
users.sign_up_ip AS ip,
|
||||||
users.created_at AS used_at
|
users.created_at AS used_at
|
||||||
|
@ -1440,7 +1440,7 @@ ActiveRecord::Schema[7.1].define(version: 2024_07_13_171909) do
|
||||||
login_activities.created_at
|
login_activities.created_at
|
||||||
FROM login_activities
|
FROM login_activities
|
||||||
WHERE (login_activities.success = true)) t0
|
WHERE (login_activities.success = true)) t0
|
||||||
GROUP BY t0.user_id, t0.ip;
|
GROUP BY user_id, ip;
|
||||||
SQL
|
SQL
|
||||||
create_view "account_summaries", materialized: true, sql_definition: <<-SQL
|
create_view "account_summaries", materialized: true, sql_definition: <<-SQL
|
||||||
SELECT accounts.id AS account_id,
|
SELECT accounts.id AS account_id,
|
||||||
|
@ -1461,9 +1461,9 @@ ActiveRecord::Schema[7.1].define(version: 2024_07_13_171909) do
|
||||||
add_index "account_summaries", ["account_id"], name: "index_account_summaries_on_account_id", unique: true
|
add_index "account_summaries", ["account_id"], name: "index_account_summaries_on_account_id", unique: true
|
||||||
|
|
||||||
create_view "global_follow_recommendations", materialized: true, sql_definition: <<-SQL
|
create_view "global_follow_recommendations", materialized: true, sql_definition: <<-SQL
|
||||||
SELECT t0.account_id,
|
SELECT account_id,
|
||||||
sum(t0.rank) AS rank,
|
sum(rank) AS rank,
|
||||||
array_agg(t0.reason) AS reason
|
array_agg(reason) AS reason
|
||||||
FROM ( SELECT account_summaries.account_id,
|
FROM ( SELECT account_summaries.account_id,
|
||||||
((count(follows.id))::numeric / (1.0 + (count(follows.id))::numeric)) AS rank,
|
((count(follows.id))::numeric / (1.0 + (count(follows.id))::numeric)) AS rank,
|
||||||
'most_followed'::text AS reason
|
'most_followed'::text AS reason
|
||||||
|
@ -1487,8 +1487,8 @@ ActiveRecord::Schema[7.1].define(version: 2024_07_13_171909) do
|
||||||
WHERE (follow_recommendation_suppressions.account_id = statuses.account_id)))))
|
WHERE (follow_recommendation_suppressions.account_id = statuses.account_id)))))
|
||||||
GROUP BY account_summaries.account_id
|
GROUP BY account_summaries.account_id
|
||||||
HAVING (sum((status_stats.reblogs_count + status_stats.favourites_count)) >= (5)::numeric)) t0
|
HAVING (sum((status_stats.reblogs_count + status_stats.favourites_count)) >= (5)::numeric)) t0
|
||||||
GROUP BY t0.account_id
|
GROUP BY account_id
|
||||||
ORDER BY (sum(t0.rank)) DESC;
|
ORDER BY (sum(rank)) DESC;
|
||||||
SQL
|
SQL
|
||||||
add_index "global_follow_recommendations", ["account_id"], name: "index_global_follow_recommendations_on_account_id", unique: true
|
add_index "global_follow_recommendations", ["account_id"], name: "index_global_follow_recommendations_on_account_id", unique: true
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue