17 lines
447 B
Python
17 lines
447 B
Python
"""SQLAlchemy Base 定义与示例模型
|
||
|
||
提供 SQLAlchemy 的 Base 供后续 ORM 模型继承。
|
||
"""
|
||
|
||
from sqlalchemy.orm import declarative_base
|
||
|
||
Base = declarative_base()
|
||
|
||
# 示例:如需添加ORM模型,可参考以下结构
|
||
# from sqlalchemy import Column, Integer, String
|
||
# class User(Base):
|
||
# __tablename__ = "users"
|
||
# id = Column(Integer, primary_key=True, autoincrement=True)
|
||
# name = Column(String(100), nullable=False)
|
||
|