fix table with handling, icons implemented

This commit is contained in:
root
2026-08-09 08:50:13 +02:00
parent 5e32be7d0c
commit 3ff0794cfc
43 changed files with 1027 additions and 95 deletions
+3
View File
@@ -88,6 +88,8 @@ ASSET_COLUMNS = {
"room_number": "VARCHAR(80) NULL",
"parent_asset_id": "INTEGER NULL REFERENCES assets(id) ON DELETE SET NULL",
"mesh_mtype": "INTEGER NULL",
"mesh_icon": "INTEGER NULL",
"visual_source": "VARCHAR(24) NOT NULL DEFAULT 'auto'",
}
@@ -106,6 +108,7 @@ def apply_lightweight_migrations() -> None:
connection.execute(text("CREATE INDEX IF NOT EXISTS ix_assets_room_number ON assets (room_number)"))
connection.execute(text("CREATE INDEX IF NOT EXISTS ix_assets_parent_asset_id ON assets (parent_asset_id)"))
connection.execute(text("CREATE INDEX IF NOT EXISTS ix_assets_mesh_mtype ON assets (mesh_mtype)"))
connection.execute(text("CREATE INDEX IF NOT EXISTS ix_assets_mesh_icon ON assets (mesh_icon)"))
inspector = inspect(engine)
with engine.begin() as connection:
if "users" in inspector.get_table_names():