implemented
This commit is contained in:
parent
40ca82bb45
commit
409e0df9a6
16 changed files with 2451 additions and 4 deletions
|
|
@ -67,6 +67,8 @@ async def upsert_user(db: AsyncSession, email: str, password: str, role_names: l
|
|||
|
||||
async def seed() -> None:
|
||||
async with engine.begin() as conn:
|
||||
# Drop all tables and recreate to ensure schema is up to date
|
||||
await conn.run_sync(Base.metadata.drop_all)
|
||||
await conn.run_sync(Base.metadata.create_all)
|
||||
|
||||
async with async_session() as db:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue