|
|
@@ -10,7 +10,7 @@ |
|
|
# |
|
|
# |
|
|
# It's strongly recommended that you check this file into your version control system. |
|
|
# It's strongly recommended that you check this file into your version control system. |
|
|
|
|
|
|
|
|
ActiveRecord::Schema[8.0].define(version: 2026_04_09_123700) do |
|
|
|
|
|
|
|
|
ActiveRecord::Schema[8.0].define(version: 2026_04_19_035400) do |
|
|
create_table "active_storage_attachments", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| |
|
|
create_table "active_storage_attachments", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| |
|
|
t.string "name", null: false |
|
|
t.string "name", null: false |
|
|
t.string "record_type", null: false |
|
|
t.string "record_type", null: false |
|
|
@@ -216,6 +216,23 @@ ActiveRecord::Schema[8.0].define(version: 2026_04_09_123700) do |
|
|
t.index ["target_tag_id"], name: "index_tag_similarities_on_target_tag_id" |
|
|
t.index ["target_tag_id"], name: "index_tag_similarities_on_target_tag_id" |
|
|
end |
|
|
end |
|
|
|
|
|
|
|
|
|
|
|
create_table "tag_versions", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| |
|
|
|
|
|
t.bigint "tag_id", null: false |
|
|
|
|
|
t.integer "version_no", null: false |
|
|
|
|
|
t.string "event_type", null: false |
|
|
|
|
|
t.string "name", null: false |
|
|
|
|
|
t.string "category", null: false |
|
|
|
|
|
t.text "aliases", null: false |
|
|
|
|
|
t.text "parent_tag_ids", null: false |
|
|
|
|
|
t.datetime "created_at", null: false |
|
|
|
|
|
t.bigint "created_by_user_id" |
|
|
|
|
|
t.index ["created_at"], name: "index_tag_versions_on_created_at" |
|
|
|
|
|
t.index ["created_by_user_id", "created_at"], name: "index_tag_versions_on_created_by_user_id_and_created_at", order: { created_at: :desc } |
|
|
|
|
|
t.index ["tag_id", "created_at"], name: "index_tag_versions_on_tag_id_and_created_at", order: { created_at: :desc } |
|
|
|
|
|
t.index ["tag_id", "version_no"], name: "index_tag_versions_on_tag_id_and_version_no", unique: true |
|
|
|
|
|
t.check_constraint "`version_no` > 0", name: "tag_versions_version_no_positive" |
|
|
|
|
|
end |
|
|
|
|
|
|
|
|
create_table "tags", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| |
|
|
create_table "tags", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t| |
|
|
t.bigint "tag_name_id", null: false |
|
|
t.bigint "tag_name_id", null: false |
|
|
t.string "category", default: "general", null: false |
|
|
t.string "category", default: "general", null: false |
|
|
@@ -394,6 +411,8 @@ ActiveRecord::Schema[8.0].define(version: 2026_04_09_123700) do |
|
|
add_foreign_key "tag_names", "tag_names", column: "canonical_id" |
|
|
add_foreign_key "tag_names", "tag_names", column: "canonical_id" |
|
|
add_foreign_key "tag_similarities", "tags" |
|
|
add_foreign_key "tag_similarities", "tags" |
|
|
add_foreign_key "tag_similarities", "tags", column: "target_tag_id" |
|
|
add_foreign_key "tag_similarities", "tags", column: "target_tag_id" |
|
|
|
|
|
add_foreign_key "tag_versions", "tags" |
|
|
|
|
|
add_foreign_key "tag_versions", "users", column: "created_by_user_id" |
|
|
add_foreign_key "tags", "tag_names" |
|
|
add_foreign_key "tags", "tag_names" |
|
|
add_foreign_key "theatre_comments", "theatres" |
|
|
add_foreign_key "theatre_comments", "theatres" |
|
|
add_foreign_key "theatre_comments", "users" |
|
|
add_foreign_key "theatre_comments", "users" |
|
|
|