chore: Backend codebase cleanup and archiving of legacy scripts
This commit is contained in:
12
backend/archive_v1_scripts/force_create_tables.py
Normal file
12
backend/archive_v1_scripts/force_create_tables.py
Normal file
@@ -0,0 +1,12 @@
|
||||
import asyncio
|
||||
from app.database import engine, Base
|
||||
import app.models # Összes modell betöltése
|
||||
|
||||
async def force_sync():
|
||||
async with engine.begin() as conn:
|
||||
# Ez a parancs az 58 modell alapján MINDENT létrehoz
|
||||
await conn.run_sync(Base.metadata.create_all)
|
||||
print("✅ Minden tábla sikeresen létrehozva a sémákban!")
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(force_sync())
|
||||
Reference in New Issue
Block a user