mirror of
https://github.com/grillazz/fastapi-sqlalchemy-asyncpg.git
synced 2025-11-30 13:20:40 +03:00
add new models to declarative base
This commit is contained in:
@@ -1,2 +1,3 @@
|
||||
from the_app.models.nonsense import Nonsense # noqa
|
||||
from the_app.models.stuff import Stuff # noqa
|
||||
from the_app.models.shakespeare import Character # noqa
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
from sqlalchemy import (Column, ForeignKeyConstraint, Integer,
|
||||
PrimaryKeyConstraint, String, Table, Text,
|
||||
UniqueConstraint)
|
||||
from sqlalchemy.orm import declarative_base, relationship
|
||||
UniqueConstraint, ForeignKey)
|
||||
from sqlalchemy.orm import relationship
|
||||
|
||||
Base = declarative_base()
|
||||
from the_app.models.base import Base
|
||||
metadata = Base.metadata
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user